HomeSection_sub_breakBlogsSection_sub_breakTechnical Blog
Icon_blog_forum_small New Paglo Crawler plugin for SNMP get requests
Icon_person
Peder Refsnes
Icon_time
07/06/2009 at 13:47
Icon_post
0 comments

My name is Peder and I’m doing a summer engineering internship here at Paglo. My first assignment has been writing a plugin for the Paglo Crawler for communicating with network devices using SNMP.

SNMP is a super useful (although archaic) protocol for gathering all sorts of important information about the resources on your network devices, be it CPU load or the amount of ink left in the color printer.

I have added a general SNMP plugin for the Paglo Crawler to expand the data that Paglo collects. The plugin uses SNMP GET requests to do this. To use the plugin, you can specify one or more object identifiers (OIDs). An OID identifies a variable that can be read through SNMP. For instance, if you want to request the CPU load over the past 5 minutes from a Cisco router you enter the OID “1.3.6.1.4.1.9.2.1.58.0”.

Each number in the OID maps to a node in a Management Information Base (MIB) tree.

The first thing you should do when using this plugin is to figure out the OIDs you want. A good place to start is www.mibdepot.com . OIDs are usually vendor specific and not all devices support all of them, so it’s also a good idea to install the net-snmp unix tools and experiment on the command line to find out what you need.

Now, to use this new plugin in Paglo you need to:
=> Log in to Paglo
=> Select the Crawlers application on the left
=> Choose the SNMP Get Plugin under Crawler→Plugins
=> Click the Custom button and add OIDs

After this step, you probably want to add a schedule for the plugin. Go to the Schedule tab (in the same Crawlers application) and create a new schedule. Something like the one shown below should be fine, just remember to add all the hosts you want the plugin to request data from.

Now you can view the data collected by doing queries for it. For example, to get all the SNMP data collected you could do:

select * from /network/device/snmp

or if you want to check against a particular IP you could use the following search:

select * from /network/device[interface/inet/ip_address = ‘10.10.10.1’]/snmp

The value of a node is merged into the PQL (Paglo Query Language) tree every time it changes. You can see the history by clicking on a value (in your search results) and choosing show history. The historical values are presented and you can display them in a chart and move them to a dashboard.

Add a Comment