monit-general
[Top][All Lists]
Advanced

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

Re: monitor and unmonitor commands fail at command line but work from MM


From: Nils Steinger
Subject: Re: monitor and unmonitor commands fail at command line but work from MMonit and Monit web portals
Date: Mon, 11 Aug 2014 01:34:24 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Wed, Aug 06, 2014 at 03:42:45PM +0000, Peter C. Valentien wrote:
> I have a group of processes for which I wish to start and stop the monitoring 
> in cron as follows:
> 
> 10 08 * * 1-5   /usr/bin/monit -g trading_call monitor
> 30 17 * * 1-5   /usr/bin/monit -g trading_call unmonitor

Why don't you just configure the times when you want the services to be
monitored in your monitrc, as described in [1]?
Your start and stop times can't be combined in a single configuration
line in Monit (at least not in any way I'm aware of), but this should
work for you:

  check <whatever>
    every "10-59 8 * * 1-5"
    every "* 9-16 * * 1-5"
    every "0-30 17 * * 1-5"


Regards,
Nils

[1]: http://mmonit.com/monit/documentation/monit.html#service_poll_time



reply via email to

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