Not sure what you're running into, but I ended up making sure the
start/stop script for Tomcat was creating a PID file (check online
documentation on that, but I believe it's as easy as exporting the
CATALINA_PID var). Added that as the "primary check" (with pidfile).
Additionally used:
if failed host 127.0.0.1 port 8080 protocol http REQUEST
"/favicon.ico" retry 3 ...
as a supplemental check. I keep the retry in there, because I have seen
it hiccup, even on localhost (don't know why).
This has been pretty solid for me.
-AJ
On 3/19/2013 10:22 AM, Charles Pino wrote:
Hello all,
i have a current Monit config that simply restarts Tomcat if it
quits, but it seems that i am having multiple Tomcat PIDs whenever
Monit restarts the service. my question would be.
1.] how do i kill or make sure the PID is killed before i execute the
restarting of the service?
i have this right now
check host tomcat with address localhost
stop program = "/sbin/service tomcat stop"
start program = "/sbin/service tomcat start"
if failed port 8080 and protocol http
then start
--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general
--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general