Hello Robert, Wes,... please help!

I wonder how can be some request droped from the registered handler in some
special case, when  I don't want to be snmp pdu genereated and returned to
the manager above?

To be a little more specific: I've registered handler 'HandleR' that takes
care for data, retriving  from underlying drivers communicating directly
with hardware through proprietary protocol. If timeout on my device for the
first time occurs, I don't wanna generate snmp pdu with error, but just want
to drop request and do not respond at all. Of course, error event is written
to the syslog of the device.

I looked at the net-snmp code, but couldn't find any flag that I can setup
from the HandleR itself. No matter what kind of exit status HandleR have,
after that netsnmp_handle_request(...) is called, which doesn't foreseen
this kind of behaviour (I will be very pleased, if i'm wrong...).



TRACE
=============================================
verbose:asp: asp 0xa267d60 reqinfo 0xa268d48 assigned to request
trace: netsnmp_add_varbind_to_cache(): snmp_agent.c, 1899:
verbose:asp: asp 0xa267d60 reqinfo 0xa268d48 assigned to request
trace: netsnmp_call_handlers(): agent_handler.c, 498:
handler:calling: main handler bulk_to_next
trace: netsnmp_call_handler(): agent_handler.c, 418:
handler:calling: calling handler bulk_to_next for mode GET
trace: netsnmp_call_handler(): agent_handler.c, 426:
handler:returned: handler bulk_to_next returned 0
trace: netsnmp_call_handler(): agent_handler.c, 418:
handler:calling: calling handler alarmDescrText for mode GET
trace: row_idx_helper_itr_can_next(): itr_helpers.c, 1556:
Called 'row_idx_helper_itr_can_next' with root oid:
.1.3.6.1.4.1.1448.2.10.1.1.1.1.4.2.101
returned object size: 10, exit code: 0
trace: netsnmp_call_handler(): agent_handler.c, 426:
handler:returned: handler alarmDescrText returned 0
trace: netsnmp_handle_request(): snmp_agent.c, 2975:
       ^^^^^^^^^^^^^^^^^^^^^^^^
results: request results (status = 0):
trace: netsnmp_handle_request(): snmp_agent.c, 2978:
results:        trace: sprint_realloc_by_type(): mib.c, 1975:
output: sprint_by_type, type 4
.1.3.6.1.4.1.1448.2.10.1.1.1.1.4.2.101.1 = STRING: "E1 loss 1
"
trace: _snmp_build(): snmp_api.c, 2879:
snmp_send: Building SNMPv2 message...
trace: _snmp_build(): snmp_api.c, 2882:
....
END OF TRACE
==========================================================


Any help, tip, advice would be encouraging...

Have a nice day,
Igor




P.S.: (System: Linux, RedHat 9.1, net-snmp 5.2.1.rc2)



Igor Grasic, Ms. D.
Development Engineer
Iskra Transmission, d. d., Ljubljana
Stegne 11, SI-1000 Ljubljana, Slovenia
phone: +386 1 5003 000
fax: +386 1 5003 500
www.iskratr.si, www.iskratr.com
........................................................



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to