Hello,

I got a problem with Monit version 5.2.3 :

I have below monitoring set.
In the log I can see more than 3 restarts but the sms alert is never launch...

Is there something wrong with the "check host syntax" ?

Note : I'm not sure of what exit code the myscript returns
       (I can see some 'exit' without any code in the script).
        What the behaviour of monit with simple 'exit' ?
        Is the restart counter dependant of start command return code ?

-------8<------------------------------------------------------------------
check host myscript with address 127.0.0.1
    start program = "/bin/su - user -c '~/etc/init.d/myscript start'"
    stop  program = "/bin/su - user -c '~/etc/init.d/myscript stop'"
    if 3 restarts within 3 cycles then exec "/root/scripts/sms_alert"
    if failed port 33300 with timeout 30 seconds then restart
    if 10 restarts within 10 cycles then timeout
    depends on proxy
-------8<------------------------------------------------------------------

Thanks for your help.
Regards.

--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general

Reply via email to