Discussion:
SNMP COMMAND Datasource graphing issue
kittytowerz
2014-02-02 16:24:17 UTC
Permalink
kittytowerz [http://community.zenoss.org/people/kittytowerz] created the discussion

"Re: SNMP COMMAND Datasource graphing issue"

To view the discussion, visit: http://community.zenoss.org/message/75660#75660

--------------------------------------------------------------
For anyone who cares; I did find the magic beans I was looking for. In the process, I also discovered that the COMMAND snmpwalk string can be modified to accomplish quite a bit more then I anticipated.

Here is the example I came up with: COMMAND type data source. Parser set to Nagios.

/usr/bin/snmpwalk -OqvU -${device/zSnmpVer} -c${device/zSnmpCommunity} ${device/manageIp} 1.3.6.1.4.1.14988.1.1.1.1.1.4.3 | sed 's/^/RX_Signal|RX_Signal=/'

In this example, the OID for this particular device was something like 1.3.6.1.4.1.14988.1.1.1.1.1.4.3.2           

Note the extra .2 at the end. The problem I was having initially is that each Mikrotik CPE in the field would have a different ending OID intiger, so I could not use a standard template in Zenoss to model all devices correctly. My assumption was that an SNMPWALK will walk as far down the tree as you specify, returning the value (singular value in this case).

So, in my command line above, I simply removed the last unique digit in the OID and snmpwalk returned the correct value. So, same template would graph correctly, as it would ignore the last digit (the one that was different from CPE to CPE).

I also discovered over the years that different RouterOS versions would alter the OID, and this could explain why same hardware was reporting different OID last digit on walk.

Another useful reason to use this type of command template is if you need to graph a value on another device and have it appear on the graph of a particular device that does not have that OID. Example, TX signal strength is not found on the CPE itself, but rather on the AP that the CPE is connected to. In this case, you can replace the ${device/manageip} variable with the actual IP of a different device (change community and ver as required as well). You can now pull data from a separate device and include the graphing value on another device where you might want the graphing to appear.

Hope anyone finds the SNMPWALK command line useful for what ever you are trying to accomplish.

Matt
--------------------------------------------------------------

Reply to this message by replying to this email -or- go to the discussion on Zenoss Community
[http://community.zenoss.org/message/75660#75660]

Start a new discussion in zenoss-users at Zenoss Community
[http://community.zenoss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2003]
Loading...