12-18-2008
12,
0
Join Date: Aug 2008
Last Activity: 31 October 2012, 2:04 PM EDT
Posts: 12
Thanks Given: 1
Thanked 0 Times in 0 Posts
Net-SNMP v5.4 - sub-id not found in log, but can query with snmpget and snmpwalk
Hi everyone,
I'm configuring Net-SNMP v5.4 on Solaris 10, sending traps to OpenNMS 1.2.9-0.20061212.0. I'm setting up disk monitoring (% of space free) for 5 directories. Here's what I'm working with:
(snmpd.conf - disk and monitoring portions)
#
# Disk Usage monitoring:
#
disk / 20%
disk /tmp 20%
disk /usr 10%
disk /opt 10%
disk /var 10%
#
# Enable Active Monitoring
#
defaultMonitors yes
monitor -i -r 5 -o dskPath -o dskErrorMsg "dskTable" dskErrorFlag !=0
(snmpd.log once SNMP is restarted)
NET-SNMP version 5.4 restarted
send response: (Sub-id not found: (top) -> dskErrorFlag)
-- IF-MIB::ifNumber.0
send response:
-- SNMPv2-MIB::sysObjectID.0
send response:
-- IF-MIB::ifNumber.0
send response:
-- SNMPv2-MIB::sysObjectID.0
send response:
-- IF-MIB::ifNumber.0
-bash-3.00$ snmpwalk -v 2c -c public localhost dskErrorFlag
UCD-SNMP-MIB::dskErrorFlag.1 = INTEGER: 0
UCD-SNMP-MIB::dskErrorFlag.2 = INTEGER: 0
UCD-SNMP-MIB::dskErrorFlag.3 = INTEGER: 1
UCD-SNMP-MIB::dskErrorFlag.4 = INTEGER: 0
UCD-SNMP-MIB::dskErrorFlag.5 = INTEGER: 0
-bash-3.00$ snmpget -v 2c -c public localhost dskErrorFlag.1
UCD-SNMP-MIB::dskErrorFlag.1 = INTEGER: 0
-bash-3.00$ snmpget -v 2c -c public localhost dskErrorFlag.3
UCD-SNMP-MIB::dskErrorFlag.3 = INTEGER: 1
So I have /opt dir at 94% tripping the flag as it should. I can query both dskErrorFlag, and dskErrorFlag.'x'.
However, when the SNMP agent tries to send dskErrorFlag to OpenNMS to generate a trap, it does not find the Sub-id. Hence the error in the log file.
Using:
snmpwalk -Dparse-mibs -v 2c -c public localhost system
to display where the MIB definitions are located, I can see it is looking in the correct directory.
Here is where I am stumped. I'm not sure what else to check, or how to fix this issue.
Any ideas?