Custom SNMP_queries
Moderators: Developers, Moderators
Custom SNMP_queries
Hello all,
I have a question, I want to write a snmp_query which will create a current user count datasource for each member server in a farm on a radware WSD.
I have all the OID's but what I am not sure about is, how to work with OID's which are formed like SO
BASEOID.<FARMIP>.<SERVERIP>
So say we have a farm which is 10.1.1.1 which has two servers 10.1.1.2 and 10.1.1.3 you send up with
BASEOID.10.1.1.1
BASEOID.10.1.1.1.10.1.1.2
BASEOID.10.1.1.1.10.1.1.3
and to get the counts for each server then its
BASEOID.<10.1.1.1>.<10.1.1.2>.<USERCOUNTOID> and
BASEOID.<10.1.1.1>.<10.1.1.3>.<USERCOUNTOID>
(bracketing to help show the format)
which I can then graph the per server and sum for the total farm stats.
So I could just hard code all the OIDS in many datasources, but I would rather do it properly and query a farm on the device and dynamically build the server list (like the interfaces do)
ideas?
I have a question, I want to write a snmp_query which will create a current user count datasource for each member server in a farm on a radware WSD.
I have all the OID's but what I am not sure about is, how to work with OID's which are formed like SO
BASEOID.<FARMIP>.<SERVERIP>
So say we have a farm which is 10.1.1.1 which has two servers 10.1.1.2 and 10.1.1.3 you send up with
BASEOID.10.1.1.1
BASEOID.10.1.1.1.10.1.1.2
BASEOID.10.1.1.1.10.1.1.3
and to get the counts for each server then its
BASEOID.<10.1.1.1>.<10.1.1.2>.<USERCOUNTOID> and
BASEOID.<10.1.1.1>.<10.1.1.3>.<USERCOUNTOID>
(bracketing to help show the format)
which I can then graph the per server and sum for the total farm stats.
So I could just hard code all the OIDS in many datasources, but I would rather do it properly and query a farm on the device and dynamically build the server list (like the interfaces do)
ideas?
I am not quite sure if this is possible with SNMP queries in Cacti currently, even though I am leaning a bit towards no. I would start with something like this:
The problem is trying to actually derive the final value (the count). Much of this problem comes from the fact that Cacti expects the "index" to be formed from a single octet.
I really would like to make data queries more useful in general, I do not have cool equipment like this to test on though. Contact me via e-mail sometime if you would want to work something out to get this coded.
-Ian[/code]
Code: Select all
<interface>
<name>blah</name>
<oid_index>BASEOID</oid_index>
<fields>
<farm>
<name>Farm IP</name>
<method>walk</method>
<source>OID/REGEXP:.*\.([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$</source>
<direction>input</direction>
<oid>BASEOID</oid>
</farm>
<server>
<name>Server IP</name>
<method>walk</method>
<source>OID/REGEXP:.*\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})$</source>
<direction>input</direction>
<oid>BASEOID</oid>
</server>
I really would like to make data queries more useful in general, I do not have cool equipment like this to test on though. Contact me via e-mail sometime if you would want to work something out to get this coded.
-Ian[/code]
I have 3 different Radware devices (WSD, CID and the DefensePro) and the relevant MIBS for the WSD and CID downloaded from Radware.
The DefensePro is different from the WSD and CID (in terms of farms) but is SNMP enabled.
So raX im willing to help out with the relevant testing if you need me to get this functionality built into cacti?
Thx,
Warren
The DefensePro is different from the WSD and CID (in terms of farms) but is SNMP enabled.
So raX im willing to help out with the relevant testing if you need me to get this functionality built into cacti?
Thx,
Warren
-
- Posts: 9
- Joined: Wed Jan 26, 2005 11:22 pm
- Location: Seattle, WA
- Contact:
-
- Posts: 9
- Joined: Wed Jan 26, 2005 11:22 pm
- Location: Seattle, WA
- Contact:
Take a look at the following thread as the user was having a very similar problem to yours.
http://forums.cacti.net/viewtopic.php?t=6779
As crazy as his MIB was, he ended up getting the data query to work using the regex OID parsing features added in 0.8.6c. If you need any additional help on this, let me know.
-Ian
http://forums.cacti.net/viewtopic.php?t=6779
As crazy as his MIB was, he ended up getting the data query to work using the regex OID parsing features added in 0.8.6c. If you need any additional help on this, let me know.
-Ian
Who is online
Users browsing this forum: No registered users and 4 guests