[Top][All Lists]

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

Re: 'restart program' directive?!

From: Jan-Henrik Haukeland
Subject: Re: 'restart program' directive?!
Date: Sun, 7 Jul 2013 19:24:43 +0200

On 07 Jul 2013, at 16:33, Josh Sharpe <address@hidden> wrote:

> I've noticed that a config like this is valid:
> check process unicorn_master
>   with pidfile /tmp/
>   start program = "/etc/init.d/unicorn start" as uid blue
>   stop program = "/etc/init.d/unicorn stop" as uid blue
>   restart program = "/etc/init.d/unicorn restart" as uid blue
> ...and by "valid" I mean, monit doesn't choke on the syntax when I restart 
> it.  So, there must be something to this "restart program" directive of which 
> I can find no documentation.
> That said, it doesn't really work either.
> "monit restart unicorn_master" is invoking the 'stop' task and then the 
> 'start' task.  Which is not ideal since stop + start doesn't produce the same 
> graceful restart that the restart init script does.
> So,
> 1) Does the directive 'restart program' exist?  Should it work?
> 2) If not, why doesn't monit choke on that directive.

Restart is only partly implemented now. The parser is done but the actual 
functionality remains. So when trying to use it, you get the old behaviour as 
you observed. The new restart command which will work as you expect will be 
completed in a later release.

reply via email to

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