It took me some time to sort it out:

I have a Gentoo vserver called "fetchmail" which runs (surprise, surprise) the "fetchmail" daemon.

Now running monit with
"check process fetchmail with pidfile /var/run/fetchmail/fetchmail.pid"
gives all sorts of strange behaviour:

- in the web front end the process "fetchmail" has only the button "disable monitoring"; "start", "stop" and "restart" are missing (though the methods are defined

- when the process is stopped via the start-stop-daemon, a "monit summary" shows the daemon still running; though it isn't. The web interface shows the system as "initializing", and the service as "running", but with an uptime of "0 minutes" (always). Monit does not restart the service.

- when the process is killed it isn't restarted either.

Now, the solution is as simple as choosing a name for the service that is different from the hostname:
"check process fetchmaild with pidfile /var/run/fetchmail/fetchmail.pid"
does work perfectly.

However, it took me some time to figure it out, and this is NOT the way I expect it to work.

Unfortunately I cannot determine whether that has something to do with vservers or not; I do not have a box I can test it. I doubt that it is a gentoo thing, either.

The behaviour shows in monit-4.10.1 (the monit version marked stable in gentoo's portage tree) and 5.0.3 (the last available version in gentoo's portage tree)

Marcus Mülbüsch


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

Reply via email to