Notes - Syslog on IOS-XR
Syslog on IOS-XR is very similar to IOS-XE.
Logging to buffer
Logging buffer is already enabled by default with a size of 2097152 bytes. To change this:
Logging to external syslog server
IOS-XR uses the syntax “logging <destination>” to log to a syslog server. Also, you define the severity level on a per-server basis.
In IOS-XE, we use “logging trap <severity>” for the severity level for syslog destinations, but on IOS-XR this command configures the severity for SNMP traps instead.
You can also set the facility, which is used to identify the application/process that generated the message on the syslog server.
You may also need to set the source-interface
Logging options
On IOS-XR, we can appended the hostname prefix to syslog messages using:
Service timestamps are configured identically to IOS-XE, using service timestamps
Duplicate messages can be suppressed using:
Log to SNMP server
We can send logs as traps using
Persistent logging
On IOS-XR, we use the “logging archive” command to configure logging to a persistent local filesystem.
Options such as the severity, frequency, max file size, etc. are configured under “logging archive”
Disabling console logging
On IOS-XE, we use “no logging console” but on IOS-XR we use:
Note that on IOS-XR no logging console simply configures the logging console settings back to default. The default setting is that logging console is enabled with severity info.
Last updated