monit-general
[Top][All Lists]
Advanced

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

restart executes multiple times


From: Alfredo Vega Weiss
Subject: restart executes multiple times
Date: Thu, 13 Nov 2003 13:36:31 -0300

I'm using monit to monitorin jboss, and I'm having several problems, and I can't undesrtand why.
 
My Monitrc says:
 
check  host host93  address 10.10.10.51
   stop  program = "/bin/echo "
   start program = "/usr/local/sbin/jboss-service restart 93"
   if failed port 9093
        protocol HTTP request "/"  then restart
I would preferred a
   stop  program = "/usr/local/sbin/jboss-service start 93"
   start program = "/usr/local/sbin/jboss-service stop  93"
 
but, my jboss-service restart does a
   stop
   sleep 5
   start
 
and I need this 5 seconds delay.
 
But, the problem was here:
 
Part of my jboss-service scripts says:
echo init >> /tmp/dbg
case..
start)
    echo start >> /tmp/dbg
stop)
   echo stop >> /tmp/dbg
...
echo end >> /tmp/dbg
 
 
After I execute  monit for the first time, the /tmp/dbg file containes
 
init
init
stop
end
init
start
end
end
As you can see, I can see 3 executions of my script, interleaved. And of course, this sometimes works, and other no.
 
Ideas???
Help????

 
Alfredo Vega Weiss
---------------------------------------
SD&D
http://www.sdd.com.ar
mail:address@hidden
--------------------------------------

reply via email to

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