I want to use name instead of oid to access data though net-snmp, so I do following work:

 

It tried on net-snmp-5.2.1.2 and net-snmp-5.2.rc4, and both are failed.

 

1. I add my private mibs into the net-snmp configure file, like this:

if test "x$mini_agent" = "xyes"; then

new_module_list="……"

default_mibs=SNMPv2-MIB:RFC1213-MIB

default_mibs_install=" "

else

new_module_list="mibII/vacm_vars mibII/vacm_conf mibII/vacm_context snmpv3mibs ucd_snmp $new_with_mib_modules"

default_mibs=IP-MIB:IF-MIB:TCP-MIB:UDP-MIB:HOST-RESOURCES-MIB:SNMPv2-MIB:RFC1213-MIB:PRIVATE-MIB

 

2. After recompile and reinstall net-snmp, I can use name to access uni-index table and scalar data.

   But, access to multi-index table fails!

   2.1 Run net-snmp with debug “snmpd -D”, the debug information stops in:

       ……

       trace: netsnmp_handle_request(): snmp_agent.c, 2975:

results: request results (status = 0):

trace: netsnmp_handle_request(): snmp_agent.c, 2978:

results: (stop here!)

   2.2 Run net-snmp without debug “snmpd”, “segment fault” appears!

 

Please help me! Thanks!

 

Reply via email to