SNMP Interface Poller help

#1

I’ve read through the wiki page for “SNMP Interface Polling” and have tried to enable it within my small test environment, however it’s not working as I would may hope/expect, so am posting here for some guidance. For reference, the test instance is using Horizon 24.0.0, installed via RPM on a CentOS 7 VM.

Scenario: For a number of devices, I am needing events/alerts being generated whenever the ifOperStatus of a monitored interface changes state. To try and limit the amount of polling, only interfaces which have an ifAdminStatus as ‘Up’ would be in scope; I may reduce that scope further, over time, but didn’t want to introduce too many variables at first. Note: I am aware that, for SNMP Trap enabled devices, linkUp/linkDown traps do exist, however, in this situation, traps are not an option and so I am going with the polling approach.

From what I was understanding from the guide, since v1.9, SNMP Interface Polling is enabled by configuring a MatchingSnmpInterfacePolicy policy within the Foreign Source defintions, providing the rules around which interfaces would be within the scope to poll. I went to the Provisioning Requisitions area, under the admin section of the web UI, editted the Foreign Source Definitions and added a MatchingSnmpInterfacePolicy, with the action of “ENABLE_POLLING”, matchingBehavior “ALL_PARAMETERS”, and added a parameter for “ifAdminStatus” as “1”. I ran a sync, just to make sure any changes were made, then checked the SNMP Interfaces for the test device I had loaded, via the Rest interface; for all the interfaces that had an ifAdminStatus as 1. the Rest service showed that ’ pollFlag = “P” poll = “true” ’ was set.

I then went into an adjacent device and brought one of the links down, causing the ifOperStatus on the affected interface to go down ( and I verified that it had changed, via snmpwalk ). No events showed up, on the device, for this change. I waited a while, still no change. I then decided to run a packet capture between the OpenNMS installation and the Cisco - I could see the SNMP requests flowing between them, but none of the 5 minute poll requests were involving ifOperStatus. I’ve tried restarting the device, restarting OpenNMS, rescanning the device and looking through the logs, but haven’t found anything yet.

What else do I need to do in order to get this working? Is this still a feature or does it have to be implemented a different way? Will it work if you are monitoring a device through a Minion ( in this test, I’m not using a Minion, but will need to soon, for some other devices )

#2

Just to follow up on this - I eventually worked it out; the instructions on the wiki mentioned needing to un-comment a service within the service-configuration.xml file, but it wasn’t commented out so I thought it was okay. Instead of commenting out, the newer format uses an attribute on the service tag to enable/disable the service; once I removed ’ enabled=“false” ’ from the SnmpPoller service and restarted, it began to work as expected.

1 Like
#3

Can you verify which wiki document you were looking at, so we can verify and update if necessary? Glad you got it working!

#4

SNMP Interface Poller Wiki Page

Its the section at the bottom of the page, related to enabling the service.