Skip to content

How to send SNMP Trap

How to Send SNMP Trap to EMS

Provide MIB File

Provide MIB file and severity mapping to EMS team or add MIB file in git repo /mibs and add the severity mapping file in git repo /severity_mappings (if no then default severity is 'low')

EMS team will convert MIB file to codebook file (git repo /codebook) for SNMP Trap Provider to convert OID to human readable event name and message.

Send Traps to SNMP Agent

Environment SNMP Agent VIP
PROD snmptraps-r.webex.com
BTS btsnmptraps-r.webex.com

Send v2c trap:

Example:

/usr/bin/snmptrap -v 2c -c public btsnmptraps-r.webex.com "" .1.3.6.1.2.1.31.2.1.9 .1.3.6.1.2.1.31.1.2.1.3 i 0 

Send v3 trap sample:

Contact EMS team to get the security settings. Security Parameter List: - security level - username - authentication protocol - authentication protocol pass phrase - privacy protocol - privacy protocol pass phrase

format:

/usr/bin/snmptrap -v 3 -l [security level] -u [username] -a [authentication protocol] \
 -A [authentication protocol pass phrase] -x [privacy protocol] -X [privacy protocol pass phrase] btsnmptraps-r.webex.com '' .1.3.6.1.6.3.1.1.5.4 .1.3.6.1.2.1.2.2.1.7 i 0 .1.3.6.1.2.1.2.2.1.1 i 2
mock example:
 /usr/bin/snmptrap -v 3 -l authPriv -u ems_snmp_user -a SHA -A ems_snmp_auth_pass -x AES -X ems_snmp_priv_pass btsnmptraps-r.webex.com '' .1.3.6.1.6.3.1.1.5.4 .1.3.6.1.2.1.2.2.1.7 i 0 .1.3.6.1.2.1.2.2.1.1 i 2

More security parameters refers to tool snmptrap.

Reference