monit-general
[Top][All Lists]
Advanced

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

Re: monit "check program" reap interval


From: Jan-Henrik Haukeland
Subject: Re: monit "check program" reap interval
Date: Fri, 15 Jun 2012 03:02:08 +0200

On Jun 15, 2012, at 1:15 AM, Leif Gustafson wrote:

> Hello,
>  The documentation for the "check program" service test in monit
> 5.3/5.4 indicates that a child process is reaped at the next cycle.  Is
> this also the case if you have configured your "check program" test to
> run every n cycles?  

No, skip has precedence, so it will wait for n cycles before reaping the 
process.

> For instance, if I configure a script to be tested
> every 5 cycles (assume a 60 second cycle interval), does monit execute
> the script and check the result in 1 minute (on the very next cycle) or
> 5 minutes (when the script is to be run again)?  

It checks in 5 minutes

> Also, does the TIMEOUT
> N SECONDS clause impact when the child is reaped?


No, only when the check is performed. At check time the test 'if 
(execution_time > timeout)' is run to decide if the program timed out. Where 
execution_time is computed as now - start time of program.

Is there a problem with the "long" reap time? As noted in the documentation, 
the caveat with the current design is that reaps are done cycle based and 
exited child processes may be in a zombie state within that time frame, but 
they _will_ be reaped. 

Also as mentioned in the doc we are refactoring away the whole poll cycle based 
engine and replace checks with an event loop and a thread-pool so checks can be 
performed at individual time and with sub-seconds resolution. This new design 
will also ensure that child-processes will be reaped when they exit. 




reply via email to

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