Jeff Sadowski
2015-03-18 19:12:02 UTC
I am looking at the passtest example in the default config file and
wanted to get that working
I found the passtest file in /usr/share/doc/net-snmp/passtest
I copied it to /scripts/passtest.sh
I noticed PLACE=".1.3.6.1.4.1.8072.2.255"
in the file
I edited /etc/snmp/snmpd.conf and added the line
pass .1.3.6.1.4.1.8072.2.255 /bin/sh /scripts/passtest.sh
like the example but with the .1.3.6.1.4.1.8072.2.255 in place of
.1.3.6.1.4.1.2021.255
I restarted snmpd
then I ran
snmpwalk -v 1 localhost -c public .1.3.6.1.4.1.8072.2.255
I got
End of MIB
I expected something similar to
# enterprises.ucdavis.255.1 = "life the universe and everything"
# enterprises.ucdavis.255.2.1 = 42
# enterprises.ucdavis.255.2.2 = OID: 42.42.42
# enterprises.ucdavis.255.3 = Timeticks: (363136200) 42 days, 0:42:42
# enterprises.ucdavis.255.4 = IpAddress: 127.0.0.1
# enterprises.ucdavis.255.5 = 42
# enterprises.ucdavis.255.6 = Gauge: 42
What am I doing wrong?
wanted to get that working
I found the passtest file in /usr/share/doc/net-snmp/passtest
I copied it to /scripts/passtest.sh
I noticed PLACE=".1.3.6.1.4.1.8072.2.255"
in the file
I edited /etc/snmp/snmpd.conf and added the line
pass .1.3.6.1.4.1.8072.2.255 /bin/sh /scripts/passtest.sh
like the example but with the .1.3.6.1.4.1.8072.2.255 in place of
.1.3.6.1.4.1.2021.255
I restarted snmpd
then I ran
snmpwalk -v 1 localhost -c public .1.3.6.1.4.1.8072.2.255
I got
End of MIB
I expected something similar to
# enterprises.ucdavis.255.1 = "life the universe and everything"
# enterprises.ucdavis.255.2.1 = 42
# enterprises.ucdavis.255.2.2 = OID: 42.42.42
# enterprises.ucdavis.255.3 = Timeticks: (363136200) 42 days, 0:42:42
# enterprises.ucdavis.255.4 = IpAddress: 127.0.0.1
# enterprises.ucdavis.255.5 = 42
# enterprises.ucdavis.255.6 = Gauge: 42
What am I doing wrong?