|Subject:||RE: [monit] Monit believes web service is up even when it is not|
|Date:||Fri, 6 Nov 2009 10:27:36 +0200|
Problem solved using verbose logging – thank you. I got confused because the configuration file had the line
if failed host 192.168.1.10 port 80 protocol http 10 times within 10 cycles then restart
and when the web server is down, Monit status page shows “online with all services” during the first 10 checks. I thought that Monit would report immediately that the service is down. I used this long 10 check delay because Domino has it’s own recovery system and Monit is standing in the back line just in case.
First problem solved and now I bumbed into another: shutting down the Domino server can take up to 2 minutes. However Monit stops and starts Domino at the same second:
[CET Nov 6 08:18:46] info : 'myserver' stop: /etc/init.d/domino
[CET Nov 6 08:18:46] info : 'myserver' start: /etc/init.d/domino
The problem is that the stop command on the first line above shuts down the server started on the second line. The /etc/init.d/domino has a ‘restart’ parameter, but as seen Monit uses ‘stop’ followed by ‘start’.
I tried another solution
if failed host 192.168.1.10 port 80 protocol http 2 times within 2 cycles then stop
if failed host 192.168.1.10 port 80 protocol http 5 times within 5 cycles then start
but the first line causes Monit to ‘unmonitor’ the server and the second line is never run.
Is there a elegant solution to get Monit pass the init script ‘restart’ parameter i.e. ‘/etc/init.d/domino restart’?
|[Prev in Thread]||Current Thread||[Next in Thread]|