|
From: | Martin Pala |
Subject: | Re: Changing one process based on another (HA setup) |
Date: | Tue, 06 Feb 2007 17:19:28 +0100 |
User-agent: | Thunderbird 1.5.0.9 (X11/20061222) |
Hi, you can try the setup described by Alexey Zilber: http://lists.gnu.org/archive/html/monit-general/2007-01/msg00006.html --8<-- check process apache with pidfile /var/run/httpd.pid start program = "/etc/init.d/httpd start" stop program = "/etc/init.d/httpd stop"if failed host 192.168.1.25 port 80 for 3 times within 5 cycles then exec "/usr/lib/heartbeat/hb_standby" if failed host 192.168.1.26 port 80 for 3 times within 5 cycles then exec "/usr/lib/heartbeat/hb_standby"
mode manual group node2 --8<-- Martin Jason wrote:
I am very impressed with monit, but I seem to be running into an issue configuring it with high availability. My ideal scenario would be:1. Start & monitor the high availability heartbeat process 2. Start & monitor my daemon process X 3. If X restarts more than 3 times within 5 cycles then timeout or stop process X and /etc/init.d/heartbeat stop (to fail over to my secondary system)I have tried using "if changed pid...then" but that apparently does not count if the pid changes due to monit, and of course, discovered that only "timeout" works with "if 3 restarts within 5 cycles then..."Can anyone provide a method to accomplish this? Thank you very much, -Jason -- To unsubscribe: http://lists.nongnu.org/mailman/listinfo/monit-general
[Prev in Thread] | Current Thread | [Next in Thread] |