[Contents] [Prev] [Next] [Index] [Report an Error]


Display System Log Messages

To display system log messages, enter JUNOS CLI operational mode and issue either of the following commands:

user@host> show log log-filename 
user@host> file show log-file-pathname 

For more information about the commands, refer to the JUNOS Internet Software Operational Mode Command Reference.

System log messages have the following syntax:

timestamp [router-name] software-process[process-ID]: message-code: message-text

Table 5 describes the fields in each message.


Table 5: Fields in System Log Messages 

System Log Message Field
Description
timestamp
Time at which the message was logged.
[router-name]
Router name.
software-process[process-ID]:
Name and process identifier (PID) of the JUNOS software process that generated the message.
message-code:
Code that identifies the type of message. The name begins with a prefix that identifies the generating software process. The entries in this manual are ordered alphabetically by this prefix.
Table 6 lists and describes the software processes that generate the messages described in this manual.
message-text
Text of the system log message.

Examples: Display System Log Messages

Display the contents of the system log file /var/log/messages. (The /var/log directory is the default location for log files, so you do not need to include it in the filename. The messages filename is a commonly configured filename.)

# cli
user@host> show log messages
Apr 11 06:27:25 [host] mgd.last[1657]: UI_SCHEMA_MISMATCH_MINOR: Schema minor version 
mismatch for pkg 6 (7. vs. 8)
Apr 11 06:27:25 [host] mgd.last[1657]: UI_DBASE_MISMATCH_SEQUENCE: Database header 
sequence numbers mismatch for file '/var/db/juniper.db'
Apr 11 06:28:00 [host] mgd[629]: UI_CHILD_WAITPID: waitpid failed: pid 637, rc -1, status ffffffff: 
No child processes
Apr 11 13:12:59 [host] mib2d[359]: SNMP_TRAP_LINK_DOWN: ifIndex 33, ifAdminStatus up(1), 
ifOperStatus down(2), ifName at-3/1/0

Display the contents of the file /var/log/snmp-traps:

# cli
user@host> file show /var/log/snmp-traps
Apr 10 19:23:41 [host] mib2d[359]: SNMP_TRAP_LINK_DOWN: ifIndex 33, ifAdminStatus up(1), 
ifOperStatus down(2), ifName at-3/1/0
Apr 10 19:23:41 [host] mib2d[359]: SNMP_TRAP_LINK_DOWN: ifIndex 25, ifAdminStatus up(1), 
ifOperStatus down(2), ifName at-3/1/0.0
Apr 10 19:23:41 [host] mib2d[359]: SNMP_TRAP_LINK_DOWN: ifIndex 21, ifAdminStatus up(1), 
ifOperStatus down(2), ifName at-3/2/0


[Contents] [Prev] [Next] [Index] [Report an Error]