The AxoSyslog application can convert the syslog messages sent by Cisco devices to Cisco-specific SNMP traps defined by the CISCO-SYSLOG-MIB (enterprises.cisco.ciscoMgmt.ciscoCiscoMIB
) is also supported (such traps are also referred to as clogMessageGenerated
notifications). That way, the incoming log messages can be forwarded to devices used to process and analyze Cisco-specific SNMP traps. For this to work correctly, the following requirements must be met:
-
The Source Configuration Library (SCL) must be included in the AxoSyslog configuration file:
-
The pattern database described in Parsing Cisco-specific message fields with patterndb must be used to parse the incoming log messages.
To accomplish this, AxoSyslog has to use a special pattern database to parse the Cisco-specific syslog messages, because these messages do not comply with the standard syslog formats.
For details on the Cisco-specific SNMP trap format, see CISCO-SYSLOG-MIB.
Parsing Cisco-specific message fields with patterndb
The ${PROGRAM}
part of the syslog messages sent by Cisco devices contain not only the program name, but other important protocol information part as well. The ${PROGRAM}
of these messages contains the Facility, Severity, and the Mnemonic (the Cisco name) of the message. The following pattern database parses these values and makes them available as the .cisco.Facility
, .cisco.Severity
, and .cisco.MsgName
, respectively. The actual log message is available as .cisco.MsgText
.
Sending clogMessageGenerated SNMP traps
To send out clogMessageGenerated SNMP traps, use the cisco_snmp()
destination driver. The cisco-snmp()
destination is actually a modified version of the snmp()
destination driver.
cisco-snmp()
driver is actually a reusable configuration snippet. For details on using or writing SCLs, see Reusing configuration blocks.
The cisco-snmp()
driver has the same requirements and options as the snmp()
destination driver, but automatically fills the clogMessageGenerated-specific fields with the data received from parsing the Cisco-specific syslog messages using the pattern database. For details on the , see the <INSTALLDIR>/ share/include/scl/snmp/plugin.conf
file.
Declaration:
Example: Defining a Cisco-specific SNMP destination
The following example defines an SNMP destination that sends out clogMessageGenerated messages using the SNMPv3 protocol.