monit-general
[Top][All Lists]
Advanced

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

Re: Monit can't restart Courier IMAP?


From: Randy Bias
Subject: Re: Monit can't restart Courier IMAP?
Date: Mon, 25 Jul 2005 15:26:46 -0700

Probably the exit code.  Trying running the script by hand then typing:

echo $?

If you get anything besides 0 then the script is not exiting nicely. Trying running it by hand with "sh -xv" to determine which step is actually generating the exit code. Then adjust the script.


--Randy



Randy Bias        randy-at-netenrich-dot-com
Director of Application Engineering & Support

On Jul 25, 2005, at 11:47 AM, Mike Jackson wrote:

I apologize in advance if this is missing critical information; I'll do my best to be thorough.

I'm running Monit 4.5.1 on a FreeBSD 5.4-STABLE box. I'm using Courier-IMAP installed from FreeBSD's ports collection, stopping/starting it with the default /usr/local/etc/rc.d scripts that the port installs. Courier starts successfully when the system loads (in other words, all the correct entries are in /etc/rc.conf), and I can run the rc.d script from the command line to stop/start/restart the service. But when Monit attempt to stop/start it, it cannot. Here's an example from /var/log/messages:

Jul 25 11:27:48 bonsai monit[42687]: 'courier-imap' failed, cannot open a connection to INET[localhost:143]
Jul 25 11:27:48 bonsai monit[42687]: 'courier-imap' trying to restart
Jul 25 11:27:48 bonsai monit[42687]: 'courier-imap' stop: /usr/local/etc/rc.d/courier-imap-imapd.sh
Jul 25 11:29:53 bonsai monit[42687]: 'courier-imap' failed to stop

The rc.d script appears to be a normal FreeBSD rc.subr script, and other similar scripts play nicely with Monit. The file permissions (0755) and ownership (root:wheel) are the same as other rc.d scripts. Any ideas?


--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general





reply via email to

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