The root cause most probably is, that monit masks signals (including
SIGTERM) for critical sections. Freebsd's /etc/rc.subr routines which
are used by monit's rc script performs the restart by stopping and
starting the process. The stop is performed by sending SIGTERM to the
process. When Monit is in critical section, it can thus ignore the
SIGTERM signal whereas the rc script thinks that it managed to
signalize process to stop and will wait for pid to exit.
It was fixed in cvs now - monit signal handlers are safe so we don't
need to block these signals at any time.
You can get the code from cvs:
http://savannah.nongnu.org/cvs/?group=monit
... or wait for next version (release candidate) which should be ready
till the end of january.
Thanks for report :)
Martin
On Jan 20, 2009, at 8:03 PM, Nicola Tiling wrote:
This is strange ... works well on freebsd-6.4 for me:
Yes - the problem exists only on that specific machine and the
occurrence happens not each time I restart monit. My other FreeBSD
machines (also 6.4.) are working fine the whole time.
I'd suggest setting logging in monit configuration + enable verbose
mode ... you can modify the following line in rc script:
command_args="-c ${default_config}"
to (added "v"):
command_args="-vc ${default_config}"
Ok. Thanks
Can you verify whether monit is running with PID for which the rc
script is waiting? (in the example it was 93378).
Yes. I killed the monit process with the pid restart told me.
Nicola
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general