monit-general
[Top][All Lists]
Advanced

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

Monit restarting app without waiting for the indicated number of cycles


From: Nadia S
Subject: Monit restarting app without waiting for the indicated number of cycles to complete (if mem > 100MB for 5 cycles then restart)
Date: Tue, 27 Sep 2011 13:45:55 -0700 (PDT)

Hello Everyone,

I have an issue with Monit restarting my application without waiting for the indicated number of cycles to complete.
Here's a snippet from my monitrc file:

check process myjavaapp with pidfile /tmp/myapp.pid

 start program = "/etc/init.d/myjavaapp start" with timeout 40 seconds

 stop program = '/etc/init.d/myjavaapp stop"

 if mem > 100 MB for 5 cycles then restart

When the 100 MB threshold is reached by the application for 5 consecutive cycles, the application is restarted. When the application comes back up, if the memory is still over 100 MB, Monit doesn't wait for 5 more cycles to restart, it reboots the application right away. Is there a way to get around this?

Ideally, I want Monit to restart the cycle counter for this process after the reboot, and not reboot again for 5 more cycles. Please let me know if you have any suggestions that I could try!

Your help is greatly appreciated!
-Nadine

reply via email to

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