We are running into some unexpected issues using god to monitor apache and 
I am trying to figure out if I'm expecting god to handle things it cannot, 
or if I've just got things set up wrong.

Basically we're using keepalive and a pid_file. We are running into a few 
issues:

1. Sometimes we accidentally restart apache directly with /etc/init.d/httpd 
stop|restart. This caused god to instantly restart apache as well, and 
there ends up being a race on the pid file, in that sometimes the pid file 
ends up not being the pid of the process that actually ends up running. 
Should I expect god to be able to handle out-of-band restarts or should I 
just ignore any complications that occur from out-of-band restarts and 
train myself to not do them.
2. We were originally using the clean_pid_file behavior, but again with the 
out-of-band restarts we're seeing a race where sometimes the pid_file is 
wiped *after* apache starts but before god does. Meaning that you end up 
with a running httpd but no pid file, and then httpd stop|restart will 
always fail since it cannot find the active process.
3. We removed clean_pid_file and now we are seeing sometimes god monitors 
the *wrong* pid, I think it's a race where god reads the pid file before 
apache "updates" it, and then god is monitoring a process_exit even on a 
random pid and that pid cycles thru every few hours on our box and when it 
exits god things apache died and "kicks" it, but even then sometimes it's 
not detecting the new pid properly (see #2) and the whole cycle starts over 
again.

All of this scares me that god isn't robust enough to be trusted, but I 
cannot tell if I'm just trying to solve an un-solvable problem with the 
out-of-band restarts.

Any advice would be appreciated.

Alan

-- 
You received this message because you are subscribed to the Google Groups 
"god.rb" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/god-rb?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to