daemon monitoring

Alex de Kruijff freebsd at akruijff.dds.nl
Sun Nov 23 17:11:39 PST 2003


Dear Will,

I've moved you text to the buttom so its more readable for other.

On Sun, Nov 23, 2003 at 04:46:09PM -0800, Will Prater wrote:
> On Nov 23, 2003, at 1:57 PM, Alex de Kruijff wrote:
> >On Sun, Nov 23, 2003 at 10:52:48AM -0800, Will Prater wrote:
> >>List,
> >>
> >>What are most of you using to monitor the running daemons? I have been
> >>loooking into DJB daemontools which seems appropriate, but are there
> >>any others that you reccomend?
> >>
> >>If DJB's daemontools is the one, could I get some more examples? I am
> >>primarily trying to keep my mail system online: postfix, cyrus,
> >>saslauthd, mysql, and spamassassin.
> >
> >I would advise Nagios.
>
> Sorry, I mispoke. I will be using Nagios to monitor, but I need to make 
> sure they will restart if there is an error. Will nagios do this as 
> well?
> 
I don't *think* so.

You could write a sh script (or any other) that does this. It could
contain this line:
result=px aux | grep SomeDaemon | wc -l

If the result is zero than SomeDaemon is not running.


-- 
Alex

Articles based on solutions that I use:
http://www.kruijff.org/alex/index.php?dir=docs/FreeBSD/


More information about the freebsd-questions mailing list