I want to create custom SNMP sensor for Cisco CUBE device to monitor dial-peer state. For example, OID 1.3.6.1.2.1.2.2.1.7.20 for dial-peer with IfIndex 20. Returning valuse are 1 (state Ok) or 2 (state Out-of-service).

I create file for custom lookup:

<?xml version="1.0" encoding="UTF-8"?>
  <ValueLookup id="prtg.custom.ciscodialpeer.state" desiredValue="1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd">
    <Lookups>
      <SingleInt state="Ok" Value="1">
        1
      </SingleInt>
      <SingleInt state="Error" Value="0">
        2
      </SingleInt>
    </Lookups>
  </ValueLookup>

When dial-peer is Ok, sensor is Ok too. Value is 1, pie chart is in green zone. But when dial-peer is down, I recieve message "Error by lookup value '2' in Value". What' wrong?


Article Comments

FTFY:

<?xml version="1.0" encoding="UTF-8"?>
  <ValueLookup id="prtg.custom.ciscodialpeer.state" desiredValue="1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd">
    <Lookups>
      <SingleInt state="Ok" Value="1">
        Dial-Peer is up.
      </SingleInt>
      <SingleInt state="Error" Value="2">
        Dial-Peer is down.
      </SingleInt>
    </Lookups>
  </ValueLookup>

The actual error value has to be 2, not one :)


Jul, 2016 - Permalink

I don't understand. I think you wrong.

OID 1.3.6.1.2.1.2.2.1.7.20 returns 1 or 2, not "Dial-Peer is up." or "Dial-Peer is down." When I use your XML I reciceve errors at both values.


Jul, 2016 - Permalink

The lookup checks for 1 and 2, "Dial-Peer is [up|down]" is only the message in the channel that is shown. Can you post a screenshot of the sensor?


Jul, 2016 - Permalink

I think I know what happening. I try SNMP Custom Lookup Sensor. It use string values, right? But my OID returns integer. What Custom Sensor I need to use? How to properly setup channel?


Jul, 2016 - Permalink

You need to use the SNMP Custom sensor : )


Jul, 2016 - Permalink