Support Support Downloads Knowledge Base Case Manager My Juniper Community

Knowledge Base

Search our Knowledge Base sites to find answers to your questions.

Ask All Knowledge Base Sites All Knowledge Base Sites JunosE Defect (KA)Knowledge BaseSecurity AdvisoriesTechnical BulletinsTechnotes Sign in to display secure content and recently viewed articles

[M/MX/T-series] How to SNMP traps to generate the BGP state changes on an NMS server

0

0

Article ID: KB24947 KB Last Updated: 06 Feb 2013Version: 1.0
Summary:
This article provides information on how to generate BGP state SNMP traps to an NMS server by using event-options.
Symptoms:
Whenever a change in the BGP state occurs, SNMP traps should be generated to the NMS server.  There are various methods to generate SNMP traps. But this article will focus on generating SNMP traps by using event-options:

Topology:
|------------BGP---------|
R1----------------------R2--------------NMS server
Description:

  • R1 and R2 are IBGP peers.

  • BGP connectivity is established by using IGP via Loopback interfaces.
Cause:

Solution:
Configuration:
event-options {

    policy BGP_STATE_CHANGE {

        events rpd_bgp_neighbor_state_changed; < this will match the BGP state change in the RPD process

        then {

            raise-trap;

        }

    } 

}



snmp {

    trap-options {

        source-address 10.141.227.12; < source address of the router

    }

trap-group SNMP_BGPCHANGE {

    targets {

        10.130.35.203; NMS server IP address

    }

}

traceoptions {

    file snmp size 2m world-readable;

    flag all;

    flag pdu;

}

}
Verification:

Use deactivate protocols bgp or interface flap and check if the SNMP trap is generated in the NMS server.
Comment on this article > Affected Products Browse the Knowledge Base for more articles related to these product categories. Select a category to begin.

Getting Up and Running with Junos

Getting Up and Running with Junos Security Alerts and Vulnerabilities Product Alerts and Software Release Notices Problem Report (PR) Search Tool EOL Notices and Bulletins JTAC User Guide Customer Care User Guide Pathfinder SRX High Availability Configurator SRX VPN Configurator Training Courses and Videos End User Licence Agreement Global Search