Hi,
i am trying to run a script on a remote machine by querying an SNMP OID.
thus i have configured my snmpd.conf with the follwoing:
exec .1.3.6.1.4.1.20011.51 /usr/local/snmp/testtcp.sh
when i query it from cacti by doing:
snmpwalk -v 1 -c public 10.12.0.11:161 .1.3.6.1.4.1.20011.51.1
i get the follwoing:
SNMPv2-SMI::enterprises.20011.51.1.1 = INTEGER: 1
SNMPv2-SMI::enterprises.20011.51.2.1 STRING: "/usr/local/snmp/testtcp.sh"
SNMPv2-SMI::enterprises.20011.51.3.1 = ""
SNMPv2-SMI::enterprises.20011.51.100.1 = INTEGER: 1
SNMPv2-SMI::enterprises.20011.51.101.1 = STRING: "No such file or directory"
SNMPv2-SMI::enterprises.20011.51.102.1 = INTEGER: 0
when i run the script from the remote machine /usr/local/snmp/testtcp.sh i get the follwoing;
established:170 listen:6 timewait:63 timeclose:0 finwait1:0 finwait2:0 synsent:0 synrecv:0 closewait:0
which is what i need for cacti to graph my data on the tcp connections or any other script that i would like to run and get data from.
help will be most appreciated
thanks in advanced
SNMP OID query a remote script!
Moderators: Developers, Moderators
Who is online
Users browsing this forum: No registered users and 6 guests