show log
Sintaxe
show log <filename | user <username>>
Sintaxe (Série QFX e Série OCX)
show log filename <device-type (device-id | device-alias)>
Sintaxe (roteador de matriz TX)
show log <all-lcc | lcc number | scc> <filename | user <username>>
Descrição
Liste arquivos de log, exibir conteúdo de arquivos de log ou exibir informações sobre usuários que fizeram login no roteador ou switch.
Nos roteadores da Série MX, modificar uma configuração para substituir uma interface de serviço por outra interface de serviço é tratado como um evento catastrófico. Quando você modifica uma configuração, toda a configuração associada à interface de serviço — incluindo grupos de NAT, regras e conjuntos de serviços — é excluída e depois recriada para a interface de serviço recém-especificada. Se houver sessões ativas associadas à interface de serviço que está sendo substituída, essas sessões serão excluídas e os pools de NAT serão liberados, o que leva à geração do NAT_POOL_RELEASE mensagens de log do sistema. No entanto, como os pools de NAT já estão excluídos como resultado da mudança de configuração catastrófico e não existem mais, as mensagens de log do sistema NAT_POOL_RELEASE não são geradas para a configuração alterada.
Opções
none | Liste todos os arquivos de log. |
<all-lcc | lcc number | scc> | (Apenas matriz de roteamento) (Opcional) Exibir informações de registro sobre todos os roteadores T640 (ou chassi de placa de linha) ou um roteador T640 específico (substitua |
device-type | (Somente sistema QFabric) (Opcional) Exibir mensagens de log para apenas um dos seguintes tipos de dispositivo:
Nota:
Se você especificar o |
(device-id | device-alias) | Se um tipo de dispositivo for especificado, exibir logs para um dispositivo desse tipo. Especifique o ID do dispositivo ou o vulto do dispositivo (se configurado). |
filename | (Opcional) Exibir as mensagens de log no arquivo de log especificado. Para a matriz de roteamento, o nome do arquivo deve incluir as informações do chassi.
Nota:
O filename parâmetro é obrigatório para o sistema QFabric. Se você não configurar um nome de arquivo de syslog, especifique o nome de arquivo padrão das mensagens. |
user <username> | (Opcional) Exibir informações de registro sobre usuários que entraram recentemente no roteador ou switch. Se você incluir |
Nível de privilégio exigido
Rastreamento
Saída de amostra
- log de exibição
- nome de arquivo de log de exibição
- nome de arquivo de log de exibição (QFabric System)
- mostrar usuário de log
- mostrar log de tráfego aceito (SRX4600, SRX5400, SRX5600 e SRX5800)
log de exibição
user@host> show log total 57518 -rw-r--r-- 1 root bin 211663 Oct 1 19:44 dcd -rw-r--r-- 1 root bin 999947 Oct 1 19:41 dcd.0 -rw-r--r-- 1 root bin 999994 Oct 1 17:48 dcd.1 -rw-r--r-- 1 root bin 238815 Oct 1 19:44 rpd -rw-r--r-- 1 root bin 1049098 Oct 1 18:00 rpd.0 -rw-r--r-- 1 root bin 1061095 Oct 1 12:13 rpd.1 -rw-r--r-- 1 root bin 1052026 Oct 1 06:08 rpd.2 -rw-r--r-- 1 root bin 1056309 Sep 30 18:21 rpd.3 -rw-r--r-- 1 root bin 1056371 Sep 30 14:36 rpd.4 -rw-r--r-- 1 root bin 1056301 Sep 30 10:50 rpd.5 -rw-r--r-- 1 root bin 1056350 Sep 30 07:04 rpd.6 -rw-r--r-- 1 root bin 1048876 Sep 30 03:21 rpd.7 -rw-rw-r-- 1 root bin 19656 Oct 1 19:37 wtmp
nome de arquivo de log de exibição
user@host> show log rpd Oct 1 18:00:18 trace_on: Tracing to ?/var/log/rpd? started Oct 1 18:00:18 EVENT <MTU> ds-5/2/0.0 index 24 <Broadcast PointToPoint Multicast Oct 1 18:00:18 Oct 1 18:00:19 KRT recv len 56 V9 seq 148 op add Type route/if af 2 addr 192.0.2.21 nhop type local nhop 192.0.2.21 Oct 1 18:00:19 KRT recv len 56 V9 seq 149 op add Type route/if af 2 addr 192.0.2.22 nhop type unicast nhop 192.0.2.22 Oct 1 18:00:19 KRT recv len 48 V9 seq 150 op add Type ifaddr index 24 devindex 43 Oct 1 18:00:19 KRT recv len 144 V9 seq 151 op chnge Type ifdev devindex 44 Oct 1 18:00:19 KRT recv len 144 V9 seq 152 op chnge Type ifdev devindex 45 Oct 1 18:00:19 KRT recv len 144 V9 seq 153 op chnge Type ifdev devindex 46 Oct 1 18:00:19 KRT recv len 1272 V9 seq 154 op chnge Type ifdev devindex 47 ... user@host:LSYS1> show log flow_lsys1.log Nov 7 07:34:09 07:34:09.491800:CID-0:THREAD_ID-00:LSYS_ID-01:RT:got route table lock Nov 7 07:34:09 07:34:09.491809:CID-0:THREAD_ID-00:LSYS_ID-01:RT:released route table lock Nov 7 07:34:09 07:34:09.491840:CID-0:THREAD_ID-00:LSYS_ID-01:RT:got route table lock Nov 7 07:34:09 07:34:09.491841:CID-0:THREAD_ID-00:LSYS_ID-01:RT:released route table lock Nov 7 07:34:09 07:34:09.491854:CID-0:THREAD_ID-00:LSYS_ID-01:RT:cache final sw_nh 0x0 Nov 7 07:34:09 07:34:09.491868:CID-0:THREAD_ID-00:LSYS_ID-01:RT:got route table lock Nov 7 07:34:09 07:34:09.491869:CID-0:THREAD_ID-00:LSYS_ID-01:RT:released route table lock Nov 7 07:34:09 07:34:09.491881:CID-0:THREAD_ID-00:LSYS_ID-01:RT:cache final sw_nh 0x0 user@host:TSYS1> show log flow_tsys1.log Nov 7 13:21:47 13:21:47.217744:CID-0:THREAD_ID-05:LSYS_ID-32:RT:<192.0.2.0/0->198.51.100.0/9011;1,0x0> : Nov 7 13:21:47 13:21:47.217747:CID-0:THREAD_ID-05:LSYS_ID-32:RT:packet [84] ipid = 39281, @0x7f490ae56d52 Nov 7 13:21:47 13:21:47.217749:CID-0:THREAD_ID-05:LSYS_ID-32:RT:---- flow_process_pkt: (thd 5): flow_ctxt type 0, common flag 0x0, mbuf 0x4882b600, rtbl7 Nov 7 13:21:47 13:21:47.217752:CID-0:THREAD_ID-05:LSYS_ID-32:RT: flow process pak fast ifl 88 in_ifp lt-0/0/0.101 Nov 7 13:21:47 13:21:47.217753:CID-0:THREAD_ID-05:LSYS_ID-32:RT: lt-0/0/0.101:192.0.2.0->198.51.100.0, icmp, (0/0) Nov 7 13:21:47 13:21:47.217756:CID-0:THREAD_ID-05:LSYS_ID-32:RT: find flow: table 0x11d0a2680, hash 20069(0xffff), sa 192.0.2.0, da 198.51.100.0, sp 0, d0 Nov 7 13:21:47 13:21:47.217760:CID-0:THREAD_ID-05:LSYS_ID-32:RT:Found: session id 0x12. sess tok 28685 Nov 7 13:21:47 13:21:47.217761:CID-0:THREAD_ID-05:LSYS_ID-32:RT: flow got session. Nov 7 13:21:47 13:21:47.217761:CID-0:THREAD_ID-05:LSYS_ID-32:RT: flow session id 18 Nov 7 13:21:47 13:21:47.217763:CID-0:THREAD_ID-05:LSYS_ID-32:RT: vector bits 0x200 vector 0x84ae85f0 Nov 7 13:21:47 13:21:47.217764:CID-0:THREAD_ID-05:LSYS_ID-32:RT:set nat 0x11e463550(18) timeout const to 2 Nov 7 13:21:47 13:21:47.217765:CID-0:THREAD_ID-05:LSYS_ID-32:RT: set_nat_timeout 2 on session 18 Nov 7 13:21:47 13:21:47.217765:CID-0:THREAD_ID-05:LSYS_ID-32:RT:refresh nat 0x11e463550(18) timeout to 2 Nov 7 13:21:47 13:21:47.217767:CID-0:THREAD_ID-05:LSYS_ID-32:RT:insert usp tag for apps Nov 7 13:21:47 13:21:47.217768:CID-0:THREAD_ID-05:LSYS_ID-32:RT:mbuf 0x4882b600, exit nh 0xfffb0006
nome de arquivo de log de exibição (QFabric System)
user@qfabric> show log messages Mar 28 18:00:06 qfabric chassisd: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:06 ED1486 chassisd: CHASSISD_SNMP_TRAP10: SNMP trap generated: FRU power on (jnxFruContentsIndex 8, jnxFruL1Index 1, jnxFruL2Index 1, jnxFruL3Index 0, jnxFruName PIC: 48x 10G-SFP+ @ 0/0/*, jnxFruType 11, jnxFruSlot 0, jnxFruOfflineReason 2, jnxFruLastPowerOff 0, jnxFruLastPowerOn 2159) Mar 28 18:00:07 qfabric chassisd: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:07 ED1486 chassisd: CHASSISD_SNMP_TRAP10: SNMP trap generated: FRU power on (jnxFruContentsIndex 8, jnxFruL1Index 1, jnxFruL2Index 2, jnxFruL3Index 0, jnxFruName PIC: @ 0/1/*, jnxFruType 11, jnxFruSlot 0, jnxFruOfflineReason 2, jnxFruLastPowerOff 0, jnxFruLastPowerOn 2191) Mar 28 18:00:07 qfabric chassisd: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:07 ED1492 chassisd: CHASSISD_SNMP_TRAP10: SNMP trap generated: FRU power on (jnxFruContentsIndex 8, jnxFruL1Index 1, jnxFruL2Index 1, jnxFruL3Index 0, jnxFruName PIC: 48x 10G-SFP+ @ 0/0/*, jnxFruType 11, jnxFruSlot 0, jnxFruOfflineReason 2, jnxFruLastPowerOff 0, jnxFruLastPowerOn 242726) Mar 28 18:00:07 qfabric chassisd: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:07 ED1492 chassisd: CHASSISD_SNMP_TRAP10: SNMP trap generated: FRU power on (jnxFruContentsIndex 8, jnxFruL1Index 1, jnxFruL2Index 2, jnxFruL3Index 0, jnxFruName PIC: @ 0/1/*, jnxFruType 11, jnxFruSlot 0, jnxFruOfflineReason 2, jnxFruLastPowerOff 0, jnxFruLastPowerOn 242757) Mar 28 18:00:16 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:16 ED1486 file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:00:27 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:27 ED1486 file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:00:50 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:50 _DCF_default___NW-INE-0_RE0_ file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:00:50 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:50 _DCF_default___NW-INE-0_RE0_ file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:00:55 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:00:55 ED1492 file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:01:10 qfabric file: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:01:10 ED1492 file: UI_COMMIT: User 'root' requested 'commit' operation (comment: none) Mar 28 18:02:37 qfabric chassisd: QFABRIC_INTERNAL_SYSLOG: Mar 28 18:02:37 ED1491 chassisd: CHASSISD_SNMP_TRAP10: SNMP trap generated: FRU power on (jnxFruContentsIndex 8, jnxFruL1Index 1, jnxFruL2Index 1, jnxFruL3Index 0, jnxFruName PIC: 48x 10G-SFP+ @ 0/0/*, jnxFruType 11, jnxFruSlot 0, jnxFruOfflineReason 2, jnxFruLastPowerOff 0, jnxFruLastPowerOn 33809)
mostrar usuário de log
user@host> show log user usera mg2546 Thu Oct 1 19:37 still logged in usera mg2529 Thu Oct 1 19:08 - 19:36 (00:28) usera mg2518 Thu Oct 1 18:53 - 18:58 (00:04) root mg1575 Wed Sep 30 18:39 - 18:41 (00:02) root ttyp2 aaa.bbbb.com Wed Sep 30 18:39 - 18:41 (00:02) userb ttyp1 192.0.2.0 Wed Sep 30 01:03 - 01:22 (00:19)
mostrar log de tráfego aceito (SRX4600, SRX5400, SRX5600 e SRX5800)
user@host> show log accepted-traffic Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.5/2->4.4.4.2/63 0x0 None 3.3.3.5/2->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2617282058 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.4/4->4.4.4.2/63 0x0 None 3.3.3.4/4->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2550162754 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.4/1->4.4.4.2/63 0x0 None 3.3.3.4/1->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2550162755 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.3/0->4.4.4.2/63 0x0 None 3.3.3.3/0->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2550162752 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.5/5->4.4.4.2/63 0x0 None 3.3.3.5/5->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2550162751 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A Jul 17 20:26:04 sourpunch RT_FLOW: RT_FLOW_SESSION_CREATE: session created 3.3.3.3/3->4.4.4.2/63 0x0 None 3.3.3.3/3->4.4.4.2/63 0x0 N/A N/A N/A N/A 17 p2 TRUST UNTRUST 2550162753 N/A(N/A) xe-7/0/0.0 UNKNOWN UNKNOWN UNKNOWN N/A N/A -1 N/A N/A N/A
Informações de versão
Comando introduzido antes do Junos OS Release 7.4.
Opção device-type (device-id | device-alias) é introduzida no Junos OS Release 13.1 para a Série QFX.