monit-general
[Top][All Lists]
Advanced

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

Re: Monit with heartbeat


From: Martin Pala
Subject: Re: Monit with heartbeat
Date: Mon, 15 Sep 2003 07:37:25 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030908 Debian/1.4-4

To avoid misunderstands, the mentioned file /var/run/myapp_start_count must be in the exclusive managment of start method (program or script specified by "start program = ..." option in monit' service check definition). On the beggining of start method you will check the state of this file, on the end you will update it.

Martin


Martin Pala wrote:

Hi,

Monit has no direct support for this feature (e.g. exec some action in the case that timeout occured). It could be possible to bypass it
in start method (count its execution ratio depending on time).

Probably it could be sufficient to store number of start attempts for example in /var/run/myapp_start_count. You can than check the timestamp of this file on the beggining of the start method and count of starts which are stored in it. If it exceedes optional limit, (for example more x starts in y minutes), you can trigger specific action to stop webserver on this node (stop or unmonitor it via monit) and start webserver on partner node. Maybe there are other (better) possibilities how to reach it.

Next option could be to implement it in monit directly - provide possibility to define the action which will be done in the case of timeout event.


Martin

Kenneth Yip wrote:

Dear all

Is it possible to use Monit with heartbeat such that in case
of Monit timeout on restarting a web server, heartbeat
can be triggered to perform a hardware failover from
one node to the other?

rgds,
Kenneth



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




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







reply via email to

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