Hi,
I am using net-snmp-5.2.2 linux 4.2. I have an
enterprise MIB which contains 2 tables. When I give snmpwalk command for a
table, it correctly returns all the entries for the table, but timesout in the
end. From the logs enabled for snmpd, I see that snmpd keeps sending a get-next
request for the last entry in the table, and it keeps getting NOSUCHINSTANCE,
but it does not go on to the next registered part in the MIB and does not
realize that the table is complete, and so the snmpwalk command timesout in the
end.
My MIB has the following :
18359(enterprises).1(ipSanMib).1(objects).1(realm).1(realmTable).1(realmEntry).1(realmIndex)
to
18359(enterprises).1(ipSanMib).1(objects).1(realm).1(realmTable).1(realmEntry).22(realmSystemTime)
18359(enterprises).1(ipSanMib).1(objects).1(realm).1(realmTable).1(realmEntry).22(realmSystemTime)
18359(enterprises).1(ipSanMib).1(objects).2(alert).1(alertTable).1(alertEntry).1(alertIndex)
to
18359(enterprises).1(ipSanMib).1(objects).2(alert).1(alertTable).1(alertEntry).9(alertDescription)
18359(enterprises).1(ipSanMib).1(objects).2(alert).1(alertTable).1(alertEntry).9(alertDescription)
From the snmpd.log
file:
handler:calling: calling handler table for mode GETNEXT
trace: table_helper_handler(): table.c, 184:
helper:table:req: Got request for handler table: base oid:SNMPv2-SMI::enterprises.18359.1.1.1.1
SNMPv2-SMI::enterprises.18359.1.1.1.1.1.22.1 ===> (realmSystemTime)
:
trace: table_helper_handler(): table.c, 184:
helper:table:req: Got request for handler table: base oid:SNMPv2-SMI::enterprises.18359.1.1.1.1
SNMPv2-SMI::enterprises.18359.1.1.1.1.1.22.1 ===> (realmSystemTime)
:
:
handler:returned: handler IntransaIpSanAlert returned 0
sparse: retry for NOSUCHINSTANCE
trace: netsnmp_call_handler(): agent_handler.c, 426:
handler:returned: handler table returned 0
trace: handle_getnext_loop(): snmp_agent.c, 2834:
results: getnext results, before next pass:
trace: handle_getnext_loop(): snmp_agent.c, 2837:
results: trace: sprint_realloc_by_type(): mib.c, 1977:
sparse: retry for NOSUCHINSTANCE
trace: netsnmp_call_handler(): agent_handler.c, 426:
handler:returned: handler table returned 0
trace: handle_getnext_loop(): snmp_agent.c, 2834:
results: getnext results, before next pass:
trace: handle_getnext_loop(): snmp_agent.c, 2837:
results: trace: sprint_realloc_by_type(): mib.c, 1977:
SNMPv2-SMI::enterprises.18359.1.1.1.1.1.22.1 is the last entry in the
table.
Fot the normal mibs like system, I saw that after the last entry for
system: SNMPv2-MIB::sysORUpTime.9 = Timeticks: (2204) 0:00:22.04, the getnext
for this goes on to IF-MIB and snmpwalk knows that it has received the complete
output for "system".
race: snmp_pdu_parse(): snmp_api.c,
4366:
dumph_recv: VarBind
trace: snmp_parse_var_op(): snmp.c, 166:
dumph_recv: Name
dumpx_recv: 06 0A 2B 06 01 02 01 01 09 01 04 09
dumpv_recv: ObjID: SNMPv2-MIB::sysORUpTime.9
trace: snmp_pdu_parse(): snmp_api.c, 4375:
dumph_recv: Value
GETNEXT message
-- SNMPv2-MIB::sysORUpTime.9
dumph_recv: VarBind
trace: snmp_parse_var_op(): snmp.c, 166:
dumph_recv: Name
dumpx_recv: 06 0A 2B 06 01 02 01 01 09 01 04 09
dumpv_recv: ObjID: SNMPv2-MIB::sysORUpTime.9
trace: snmp_pdu_parse(): snmp_api.c, 4375:
dumph_recv: Value
GETNEXT message
-- SNMPv2-MIB::sysORUpTime.9
:
:
trace: netsnmp_add_varbind_to_cache(): snmp_agent.c, 1901:
snmp_agent: tp->start SNMPv2-MIB::sysORUpTime, tp->end SNMPv2-MIB::sysOREntry.5,
snmp_agent: tp->start SNMPv2-MIB::sysORUpTime, tp->end SNMPv2-MIB::sysOREntry.5,
:
:
trace: netsnmp_add_varbind_to_cache(): snmp_agent.c, 1901:
snmp_agent: tp->start SNMPv2-MIB::sysOREntry.5, tp->end IF-MIB::ifNumber,
snmp_agent: tp->start SNMPv2-MIB::sysOREntry.5, tp->end IF-MIB::ifNumber,
What change do I need to do so that I can get a snmpwalk successfully
completed instead of a timeout, after it has finished displaying all the
values?
Is the mail chain : "Re: Repost: Retrieving scalar objects" from the
archives related to this problem?
Thanks & Regards,
Amita
