[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [monit-dev] control: consume less CPU time while waiting for a proce
From: |
Thomas Petazzoni |
Subject: |
Re: [monit-dev] control: consume less CPU time while waiting for a process to start/stop |
Date: |
Fri, 4 May 2012 21:57:24 +0200 |
Hello Martin,
Le Fri, 4 May 2012 21:08:13 +0200,
Martin Pala <address@hidden> a écrit :
> thanks for the patch, the process status polling was really too
> agressive for low power devices. I have refactored the
> wait_start/wait_stop little bit more:
>
> 1.) the wait starts with 50ms and then doubles each cycle until 1s is
> reached (50ms -> 100ms -> 200ms -> 400ms -> 800ms -> 1s) and then
> monit continues polling every 1 second. This way it allows to detect
> fast starting/stopping services state quickly and gradually slow down
> the polling if the service state change takes longer.
>
> 2.) the wait will now always sleep for the initial period (50ms) -
> originally the wait was called immediately after start/stop program
> spawn which was too fast in most cases
>
> 3.) the wait is made resistant to large time changes
>
> The fix will be part of upcoming Monit 5.4 which should be available
> tomorrow.
Great, sounds good.
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com