[Sorry for the delay in responding to this]
2008/4/3 Christer Ekholm <[EMAIL PROTECTED]>:
> I am learning to coding MIBs. My problem is that my module is not answering
> to MODE_GET message. Here is code
[snip]
> Here is snmp agent output
>
> NET-SNMP version 5.0.9
> nstAgentPluginObject2: Got request, mode = 160:
> nstAgentPluginObject2: Got get, value = 69:
> nstAgentPluginObject2: snmp_set_var_typed_value returned 0
> nstAgentPluginObject2: Got request, mode = 160:
> nstAgentPluginObject2: Got get, value = 69:
> nstAgentPluginObject2: snmp_set_var_typed_value returned 0
> nstAgentPluginObject2: Got request, mode = 160:
> nstAgentPluginObject2: Got get, value = 69:
> nstAgentPluginObject2: snmp_set_var_typed_value returned 0
> Here is snmpget output
>
> -bash-3.00# snmpget -c private localhost
> NET-SNMP-TUTORIAL-MIB::nstAgentPluginObject2.0
> Timeout: No Response from localhost.
> -bash-3.00#
I can't immediately see anything wrong with your code.
And since things are working for the first two objects,
this is unlikely to be access control (which is the usual
cause of request timeouts).
All I can suggest is running with
snmpget -r 0 -d ......
(to turn off retransmissions, and show raw packets in/out).
I presume you only see one (outgoing) packet displayed?
Nothing coming back?
As far as the agent is concerned, it certainly looks as if
the handler is processing the request correctly.
If you run the single command above (including -r 0),
I presume you only see a single set of nstAgentPluginObject2
debug output?)
Try running the agent using 'snmpd -f -Le -d ....'
and make the same request. This will show raw
packet dumps in/out. Check that this matches the
traffic seen by the snmpget command.
It might also be worth running the agent using
-Dhelper:instance
to see what the instance helper is seeing for this
request.
Dave
-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
Don't miss this year's exciting event. There's still time to save $100.
Use priority code J8TL2D2.
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders