This is a discussion on Re: Problem in explicit call to run_alarams function from "trap within the SNMP Coders forums, part of the Networking and Network Related category; Thanks for replying Sir, I have one more query, my trap sending subagent will not call "Net-SNMP 'receive()' ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Thanks for replying Sir,
I have one more query, my trap sending subagent will not call "Net-SNMP 'receive()' routine as the event loop, or 'agent_check_and_process()' to handle incoming PDUs", it receive infomation from third process convert that infomation into snmp trap & send those to snmpd, i.e flow is like this, Application ------> Trap sending Subagent -----> snmpd ---------> (Information ( Convert info to trap & ( Net-snmp agent) for trap) send it to snmpd ) So for my subagent will not call run_alarms any how that's why i am calling run_alarms explcitly before sending trap so that subagent will connect to main agent(if Ping interval expires, this check is done in run_alarms function), so Is this is correct way to solve this riddle ? Please help me out of this problem, Or is there any API in net-snmp so as to take care above problem ? Please help me, Thanks in adavance. Regards Bhushan On 4/11/07, Dave Shield <D.T.Shield@csc.liv.ac.uk> wrote: > On 11/04/07, bhushan <sonawanebhushan@gmail.com> wrote: > > In my application snmpd will stop at any point in time & start again so > for > > my subagent it is > > difficult to know that snmpd stop for same time & started again > > That's already handled by the agentx subagent framework. > See the directive 'agentXPingInterval' in snmpd.conf(5) > > > > > so my question is calling "run_alarms" explicitly from subagent code will > > be safe or not ? > > It should be OK, since it's part of the normal operation of an agent or > subagent. If you use the Net-SNMP 'receive()' routine as the event > loop, or call 'agent_check_and_process()' to handle incoming PDUs, > then these already call 'run_alarms()' anyway. > > If there's nothing due to be run, then run_alarms() will return without > doing anything, so there shouldn't be any problem in calling it at other > times too. It might waste a little bit of processing time, but that should > be all. > > Dave > -- bhushan. E . Sonawane ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?p...rge&CID=DEVDEV _______________________________________________ Net-snmp-coders mailing list Net-snmp-coders@lists.sourceforge.net https://lists.sourceforge.net/lists/...et-snmp-coders |
![]() |
| Thread Tools | |
| Display Modes | |
|
|