Navigation Menu
Graph BGP Neighbors

Graph BGP Neighbors


This Cacti data query makes it easy to graph prefixes in memory, messages rx, and messages tx on Cisco routers. If you are new to Cacti, check it out here: It can be useful to graph BGP tables to get a baseline of usage before a problem strikes. This is especially useful when doing iBGP and eBGP because usage will not always be the same on both. Once a bit of history is collected, it is easy to track down new problems as the crop up.


Cacti Wiki

Cacti Forums

Versioned Code


eBGP/iBGP Monitor uses a SNMP Data Query to poll a Cisco router for all BGP Neighbors and provide graphs for them.

    • Prefixes: This is the number of prefixes in memory on the router divide by 1000K to allow easier of viewing with Messages RX/TX on the same graph
    • Messages RX: This is the number of messages that were received over the polling period
    • Messages TX: This is the number of messages that were sent over the polling




The following two files are required

  • cacti_ebgp_ibgp.xml: template which is imported in the web interface
  • ebgp_ibgp.xml: snmp data query which resides on the server


    • Copy the ebgp_ibgp.xml file to your Cacti server,
    • Import the templates in your cacti web interface

    • Once you save you should see something like this. You can ignore some of the red text.
    • Go to the router you would like to add BGP graphing to and add the data query
    • After adding the data query, click on verbose query to make sure everything is working well
    • You should see output similar to the following

    • Add the graphs. The link is in the top right corner
    • Finally, after a few minutes you should have a graph that looks similar to this.


  1. Can you make the source for this available again somewhere? Google code is not working anymore

    • So, sadly, I can’t find the code anywhere 🙁 I will be taking this page down. I “might” be able to get the code back. I am going to look in some backups…


  1. Systems Administrator's Lab: Cacti Development | Crunch Tools - [...] Graph BGP Neighbors [...]

Post a Reply

Your email address will not be published.