The code that I used is basically the same as the one of the tutorial http://www.net-snmp.org/tutorial/tutorial-5/toolkit/demoapp/index.html.
I close the session at the end of the function. When I open the session the next time I execute the function everything works fine. But when the computer that has the snmp agent switches to the other it doesn't work. I think that there might be an other step besides closing the session. I tried to use snmp_shutdown, but then I can not ever reopen the session after I execute it.

I am really stuck with this, perhaps someone can take a look at the sources of the tutorial and tell me if using all that code inside a function is a bad approach.

Thanks,
            Rafael Garabato


On 9/1/05, Robert Story <[EMAIL PROTECTED]> wrote:
On Thu, 1 Sep 2005 09:31:54 -0300 Rafael wrote:
RG> Both computers have the same "snmpd.conf" file. Besides, supposing that
RG> the engineId and incremented engineBoots values were different, I still
RG> can use my function when I exit the CLI and start it again. There must be
RG> a way to clean all the variables so that, from the function perspective,
RG> it seems that the CLI was re-started.

Sure, close the session and re-open it.

--
NOTE: messages sent directly to me, instead of the lists, will be deleted
      unless they are requests for paid consulting services.

Robert Story; NET-SNMP Junkie
Support: <http://www.net-snmp.org/> <irc://irc.freenode.net/#net-snmp>
Archive: < http://sourceforge.net/mailarchive/forum.php?forum=net-snmp-coders>

You are lost in a twisty maze of little standards, all different.

Reply via email to