monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [monit] dependance not configured correctly


From: Martin Pala
Subject: Re: [monit] dependance not configured correctly
Date: Tue, 05 Feb 2008 22:01:15 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.11) Gecko/20071119 Iceape/1.1.7 (Debian-1.1.7-1)

Hi,

the pid change rule most probably won't do the trick, since it is
executed only when the service is running, but pid changed out of monit control. You should add the freeradius monitoring enable/disable to postgres startup script and set the freeradius monitoring mode to manual.

Martin



Barry wrote:
Hallo List

I’ve installed monit 4.8.1 on my ubuntu server and here is my control file:

check process freerad with pidfile /var/run/freeradius/freeradius.pid

        start program = "/etc/init.d/freeradius start"

        stop program = "/etc/init.d/freeradius stop"

        if changed pid then restart

        depends on postgres

check process postgres with pidfile /var/run/postgresql/8.2-main.pid

        if changed pid then unmonitor

        if failed port 5432 protocol pgsql then unmonitor

What I am trying to achieve is that freeradius is only monitored while postgres is running.

When postgres is stopped, freeradius monitoring should also stop and when postgres is started, freeradius monitoring should start.

The above config keeps on restarting freeradius whether postgres is running or not.

Any help will be appreciated.

Kind regards

Barry


------------------------------------------------------------------------

--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general




reply via email to

[Prev in Thread] Current Thread [Next in Thread]