Greetings - I dug around a bit and I couldn't find a definitive answer to this question, apologies if it's been covered before. A box running a apache 2.2 -> mongrel cluster for a rails app got power cycled at my ISP. Unfortunately monit couldn't start the mongrel processes because the pid files were still there. Here is my monit config (for each mongrel process):
check process myapp_mongrel_8000 with pidfile /data/wwwroot/myapp.com/ log/mongrel.8000.pid start program = "/usr/bin/mongrel_rails start -d -e production -p 8000 -a 127.0.0.1 -P log/mongrel.8000.pid -c /data/ wwwroot/myapp.com --user mongrel --group mongrel" stop program = "/usr/bin/mongrel_rails stop -P log/mongrel. 8000.pid -c /data/wwwroot/myapp.com" if failed host 127.0.0.1 port 8000 protocol http and request "/" then alert if cpu is greater than 60% for 2 cycles then alert if cpu > 80% for 5 cycles then restart if loadavg(5min) greater than 10 for 8 cycles then restart if 3 restarts within 5 cycles then timeout Is there some other command line switch I can add to avoid this problem? Should I config monit to clear the .pid files first? Thanks, Henry _______________________________________________ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users