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 <[EMAIL PROTECTED]> wrote:
> On 11/04/07, bhushan <[EMAIL PROTECTED]> 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?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to