UTM Custom
BGP Status Sensor

Let us create custom sensors specifically for your needs

PRTG BGP peer connection state Case Study

A client has over 10 locations in Victoria, and several locations in New South Wales and Tasmania. All locations are connected with diverse route paths and BPG protocol has been setup on all the routers to handle connection drops and routing.

 

The client doesn’t have a convenient way of knowing when a connection drops and the BGP peer changes the route, which happens automatically. This means that the network team cannot jump on right away to assess the issue and only get notified when users are calling that the links have slowed down.

 

Adding BGP peer connections OIDs to PRTG is a manual task that is different to each router and is time consuming. UTM has created a custom Sensor that does an SNMP walk on each router and also has a custom Value Lookup for alerting when the BGP status has changed.

Sensor Overview

Before starting the sensor, we looked up the BGP OID value and the “The BGP peer connection state”.

 

The documentation shows that there are 6 values that can be returned

 

  • idle(1)
  • connect(2)
  • active(3)
  • opensent(4)
  • openconfirm(5)
  • established(6)

 

Channel Value Lookup

A value lookup file was created to capture the status of the values required.

<?xml version="1.0" encoding="UTF-8"?>
<ValueLookup desiredValue="6" id="prtg.standardlookups.UTM.bgp.status" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd">
  <Lookups>
    <SingleInt state="Error" value="-1">Undefined</SingleInt>
    <SingleInt state="Warning" value="1">Idle</SingleInt>
    <SingleInt state="Warning" value="2">Connect</SingleInt>
    <SingleInt state="Warning" value="3">Active</SingleInt>
    <SingleInt state="Ok" value="4">Opensent</SingleInt>
    <SingleInt state="Ok" value="5">Openconfirm</SingleInt>
    <SingleInt state="OK" value="6">Established</SingleInt>
  </Lookups>
</ValueLookup> 

A PowerShell script was written to do an SNMP walk on the BGP OID and return the values and  status of each link.

 

One important line to note is the following:

 

$XMLOutput += Set-PrtgResult -Channel $Channel -Value $BGP.Value -Unit "Custom" -ValueLookup "prtg.standardlookups.UTM.bgp.status" -ShowChart 

The above line returns a PRTG friendly result of the Channel name, value and also links this to the value lookup file created for this sensor 

Channel Data and Settings

Get more control of your alerting by customising each channel.

 

The custom value lookup file specified that one status would send and alert, and three of the status would send a warning based on the value returned each time an SNMP walk was executed.