RE: Gracefully restart an agent

"Peter Marinec" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
I don't think it matters what I'm SETting -

I looked further into the versionRestartAgent, and found that the hook
it uses to do the restart isn't run on a Win32 platform (without
cygwin)...

in "agent\mibgroup\util_funcs.c" -

restart_hook() only does actual work if SIGALRM is defined (not so on
a win32 build), which in turn calls restart_doit(), which only does
work if HAVE_EXECV is defined (not so on a win32 build)

Any way around this? (again, like i said in all the messages, this is
on a WIN32 build)

-Pete


RE: Gracefully restart an agentFrom: Marinec, Peter
<peter.marinec@lm...> - 2007-06-14 15:34
I SET the string objects from an agent using skeleton code from the
MIB2C script & create a watcher for them..

I also noticed that some of the alarms I set during initialization which
send out notifications aren't resent upon SETting versionRestartAgent.

My impression was that setting versionRestartAgent to 1 would cause a
soft-restart - pretty much a CTRL+C & load the daemon again, without
having to do anything at the console... Is this incorrect?

Thanks
-Pete

-----Original Message-----
From: dave.shield@go... [mailto:dave.shield@go...] On
Behalf Of Dave Shield
Sent: Thursday, June 14, 2007 8:23 AM
To: Marinec, Peter
Cc: net-snmp-users@li...
Subject: Re: Gracefully restart an agent

On 14/06/07, Marinec, Peter <peter.marinec@lm...> wrote:
> The agent I built includes the UCD-SNMP-MIB, and I can see the value
> get SET to 1 (any subsequent GETs on the agent show the value as 0),
> however my agent isn't reset to default values.. i.e. I SET a string
> prior to setting the versionRestartAgent, and a minute after, I do a
> GET on the string, which responds with the same value I set it to, not

> the default..



> Which string object are you SETing?
> Many MIB objects are designed to retain values across an agent restart,
> so this may well be the expected behaviour.

> Dave

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.