monit-dev
[Top][All Lists]
Advanced

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

Re: 4.0 showstopper?


From: Jan-Henrik Haukeland
Subject: Re: 4.0 showstopper?
Date: Wed, 17 Sep 2003 22:53:09 +0200
User-agent: Gnus/5.1002 (Gnus v5.10.2) XEmacs/21.4 (Reasonable Discussion, linux)

Martin Pala <address@hidden> writes:

> - there are more then one monitored services which uses the same start
> method
> - or there are more then one test inside monitored service which uses
> the same start method
>
> The first case (more then one service using the same start method)
> seems like configuration error (dependency can be used), but the
> second case can occure in praxis, for example:
>
>   check process myprocess with pidfile /var/run/myprocess.pid
>     start program = "/etc/init.d/myprocess start"
>     stop program = "/etc/init.d/myprocess stop"
>     if failed port 80 then restart
>     if failed port 443 then restart
>
> Monit will test all ports regardless of the particular result. In the
> case that the first will fail, monit will call stop and start methods
> via restart event and continue the testing immediately.

Not for restart I think? In eval_action():validate.c, FALSE is
returned which will later in the call stack lead to abortion of more
tests on the service. For exec and alert the test will continue, but
not for restart. In other words, if the first port test should fail,
monit will restart the service and not execute the second port test,
i.e. at 443. At least this is how things look when I read the code.

Admittedly there may be some issues with race conditions. I do not
feel completely confident that we have fixed everything, but I think
or rather I hope we have. With the sendmail fix I think we can release
monit tomorrow, or what do you think? 

-- 
Jan-Henrik Haukeland




reply via email to

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