you can either add a line like this to /etc/inittab and then kill -HUP 1

sn:2345:respawn:/path/to/snmpd -c /path/to/snmpd.conf -Lsd ..... rest of 
switches

or you can google and learn daemontools which gives more control.

but don't take my word for it, go learn about init and learn about 
daemontools.

never just paste in something like this without knowing what it means...

oh course, your snmpd shouldn't be dying in the first place... perhaps 
you can fix that and then you won't have to bother with this thing?

I do have many services under these methods, but snmpd is not one of 
them as it usually shouldn't be necessary...

-h

Hari Sekhon



Jayanthi Pachaiyappan wrote:
>
> Hi Hari,
> Do u have any sample script for doing the same.
>
>
> Regards,
> Jayanthi P
>
>
> *Hari Sekhon <[EMAIL PROTECTED]>*
>
> 09/12/2007 03:49 PM
>
>       
> To
>       Jayanthi Pachaiyappan/CHE/[EMAIL PROTECTED]
> cc
>       [email protected]
> Subject
>       Re: To self start snmpd when it is killed.
>
>
>
>       
>
>
>
>
>
> what about putting the snmp daemon under init or daemontools? You can
> use this instead of a startup script.
>
> either of these can immediately restart processes when they die.
>
> -h
>
> Hari Sekhon
>
>
>
> Jayanthi Pachaiyappan wrote:
> >
> > Hi EveryBody,
> > Actually in my project, the snmpd process will be running.
> > Due to some reason if it gets killed, then can be it be self-started
> > again.
> > I know that if the workstation reboots, snmpd will self-start.
> > But for my requirement, it has to self-start when the workstation is
> > running.
> > Please help me in this regard.
> >
> > Regards,
> > Jayanthi P
> >
> > ***********************  Aricent-Private   ***********************
> > "DISCLAIMER: This message is proprietary to Aricent and is intended 
> solely for the use of
> > the individual to whom it is addressed. It may contain privileged or 
> confidential information and should not be
> > circulated or used for any purpose other than for what it is 
> intended. If you have received this message in error,
> > please notify the originator immediately. If you are not the 
> intended recipient, you are notified that you are strictly
> > prohibited from using, copying, altering, or disclosing the contents 
> of this message. Aricent accepts no responsibility for
> > loss or damage arising from the use of the information transmitted 
> by this email including damage from virus."
> >        
> >
> > ------------------------------------------------------------------------
> >
> > 
> -------------------------------------------------------------------------
> > This SF.net email is sponsored by: Microsoft
> > Defy all challenges. Microsoft(R) Visual Studio 2005.
> > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > 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
> >  
>
>
>
>
> ***********************  Aricent-Private   ***********************
> "DISCLAIMER: This message is proprietary to Aricent and is intended solely 
> for the use of 
> the individual to whom it is addressed. It may contain privileged or 
> confidential information and should not be 
> circulated or used for any purpose other than for what it is intended. If you 
> have received this message in error, 
> please notify the originator immediately. If you are not the intended 
> recipient, you are notified that you are strictly
> prohibited from using, copying, altering, or disclosing the contents of this 
> message. Aricent accepts no responsibility for 
> loss or damage arising from the use of the information transmitted by this 
> email including damage from virus."
>         
>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
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

Reply via email to