unique action handling

Issue #88 resolved
Michael Bakker
created an issue

Hi,

let me first show you the following configuration:


check host webserver with address 127.0.0.255 if failed port 80 protocol http request "/serverawake.php" status != 502 timeout 10 seconds then restart if failed port 80 protocol http request "/serverawake-modphp54.php" status != 502 timeout 10 seconds then restart if 5 restarts within 5 cycles then timeout restart program = "/usr/local/sbin/webserver.py restart" with timeout 60 seconds


In this case when both protocol checks failed monit will execute the given restart program twice. Is this behavior really intended? I can imagine that this maybe makes sense for "alert" action but for all other actions I would appreciate a unique action handling. Whats your opinion about that issue?

Comments (3)

  1. Tildeslash repo owner

    It is an unwanted side-effect, which should be fixed in the upcoming 5.9 version. In the new version, restart will be sequential meaning that restart will be called and waited for before continuing with the next test. Of course if restart didn't help the next test will also try to restart. Maybe change one of them to alert only? If you care to test, download Monit 5.9 dev and let us know how it went.

  2. Log in to comment