I have installed and configured sysutils/monit on my server and it is working great will all daemons except one. When configuring the config file to monitor a daemon you use the following:
As you can see it uses a pid file as part of the check process.
I want to monitor mail/spamass-milter but this uses a .sock file rather. I have tried the following unsuccessfully:
But this didn't work. Does anyone know how I can monitor a daemon that uses a .sock file with monit?
Thanks.
Code:
check process ntpd with pidfile /var/run/ntpd.pid
start program = "/etc/rc.d/ntpd start"
stop program = "/etc/rc.d/ntpd stop"
if failed host 127.0.0.1 port 123 type udp then alert
As you can see it uses a pid file as part of the check process.
I want to monitor mail/spamass-milter but this uses a .sock file rather. I have tried the following unsuccessfully:
Code:
check file spamass-milter with path /var/run/spamass-milter/spamass-milter.sock
start program = "/usr/local/etc/rc.d/spamass-milter start"
stop program = "/usr/local/etc/rc.d/spamass-milter stop"
if failed unixsocket /var/run/spamass-milter/spamass-milter.sock then restart
if 3 restarts within 5 cycles then timeout
But this didn't work. Does anyone know how I can monitor a daemon that uses a .sock file with monit?
Thanks.