SNMP Traps and Informs

October 29, 2008 at 12:28 pm | In System Management | Leave a Comment

IEWB-vol1-v5 Task 12.17:

Configure R4 to send traps and informs about link status (except Serial interfaces) to management stations.

R4:
snmp-server enable traps snmp linkdown linkup
snmp-server host 155.1.146.101 inform version 2c CISCO
snmp-server host 155.1.146.100 CISCO
!
interface Serial0/0
no snmp trap link-status
!
interface Serial0/1
no snmp trap link-status

Verification

Rack1R4#sh snmp host
Notification host: 155.1.146.101        udp-port: 162   type: inform
user: CISCO     security model: v2c

Notification host: 155.1.146.100        udp-port: 162   type: trap
user: CISCO     security model: v1
Rack1R4#debug snmp packet
SNMP packet debugging is on
Rack1R4#c
Enter configuration commands, one per line.  End with CNTL/Z.
Rack1R4(config)#int e0/0
Rack1R4(config-if)#shut
Rack1R4(config-if)#
*Apr  7 17:20:47.354: %LINK-5-CHANGED: Interface Ethernet0/0, changed state to administratively down
*Apr  7 17:20:48.354: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/0, changed state to down
*Apr  7 17:20:48.354: SNMP: Inform request, reqid 12, errstat 0, erridx 0
 sysUpTime.0 = 1558882
 snmpTrapOID.0 = snmpTraps.3
 ifIndex.1 = 1
 ifDescr.1 = Ethernet0/0
 ifType.1 = 6
 lifEntry.20.1 = administratively down
*Apr  7 17:20:48.442: SNMP: Packet sent via UDP to 155.1.146.101.162
*Apr  7 17:20:48.442: SNMP: Queuing packet to 155.1.146.100
*Apr  7 17:20:48.442: SNMP: V1 Trap, ent snmpTraps, addr 155.1.45.4, gentrap 2, spectrap 0
 ifIndex.1 = 1
 ifDescr.1 = Ethernet0/0
 ifType.1 = 6
 lifEntry.20.1 = administratively down
Rack1R4(config-if)#
*Apr  7 17:20:48.694: SNMP: Packet sent via UDP to 155.1.146.100

SNMP agents can send Informs or Traps

Traps are messages alerting the SNMP manager to a condition on the network
Informs are traps that require ACK from SNMP manager. Inform are more reliable than Traps

The snmp-server host command is used in conjunction with the snmp-server enable command. Use the snmp-server enable command to specify which SNMP notifications are sent globally. For a host to receive most notifications, at least one snmp-server enable command and the snmp-server host command for that host must be enabled.

Doc CD Navigation

No Comments Yet »

RSS feed for comments on this post. TrackBack URI

Leave a comment

You must be logged in to post a comment.

Blog at WordPress.com. | Theme: Pool by Borja Fernandez.
Entries and comments feeds.