snmp-server traps bgp updown
To enable Border Gateway Protocol (BGP) to receive Simple Network Management Protocol (SNMP) notifications when a BGP peer changes state in IPv4 neighbor sessions, use the snmp-server traps bgp updown command in global configuration mode.
snmp-server traps bgp [updown]
Syntax Description
bgp |
Specifies IPv4 neighbor sessions. |
updown | (Optional) Specifies trap notifications. |
Command Default
SNMP notifications are disabled by default.
Command Modes
Global configuration
Command History
Release | Modification |
---|---|
Release 7.0.1 |
This command was introduced. |
Usage Guidelines
SNMP notifications are sent as traps.
BGP generates traps when:
-
A neighbor’s session state has changed.
-
A neighbor prefix limit has exceeded.
-
A neighbor prefix count is under the limit.
Multiple traps can be generated when the neighbor is not in steady state.
Configure snmp-server traps bgp updown command to prevent the generation multiple traps.
When you configure the snmp-server traps bgp updown command, traps are sent out only when the BGP neighbor goes to established state or moves out from the established state. The prefix limit traps remain unaffected.
When you configure the bgp keyword, traps are sent for IPv4 neighbor sessions only.
Examples
The following example shows how to enable the router to send BGP state-change notifications to the host at the address myhost.cisco.com using the community string defined as public in IPv4 neighbor sessions only:
Router(config)# snmp-server traps bgp updown
Router(config)# snmp-server host myhost.cisco.com version 2c public
Related References