monit-general
[Top][All Lists]
Advanced

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

RE: monit 4.7 and check file existence - patch


From: P Holdaway
Subject: RE: monit 4.7 and check file existence - patch
Date: Fri, 13 Jan 2006 11:25:53 -0800

Seems very nice now :-)

FYI, I use a file's timestamp as a watchdog timer reset.

Processes that I have under the control of monit regularly update the
timestamp on these files and hence "hung" processes are easily detected and
restarted by monit.

For example...
####################################

check file AppManager_restart with path "/var/lxs/run/AppManager.monit"
        if timestamp > 2 minutes for then exec "/opt/lxs/bin/lxs.sh stop
AppManager"
        depends on AppManager
        group lxs

check process AppManager with pidfile "/var/lxs/run/AppManager.pid"
        start program = "/opt/lxs/bin/lxs.sh start AppManager"
        stop  program = "/opt/lxs/bin/lxs.sh stop AppManager"
        if memory > 200 MB for 5 cycles then restart
        group lxs

####################################

Thanks for the very prompt fix.

Cheers,

  Peter

> -----Original Message-----
> From: address@hidden
> [mailto:address@hidden
> On Behalf Of Jan-Henrik Haukeland
> Sent: Friday, 13 January 2006 5:00 AM
> To: This is the general mailing list for monit
> Subject: Re: monit 4.7 and check file existence - patch
> 
> 
> On 13. jan. 2006, at 10.02, Martin Pala wrote:
> 
> > I think it will be better to remove it ... in the case of problem,
> > monit will detect it in the first cycle and can take corrective
> > actions as configured (for example run 'restart' method which will
> > fix the problem).
> 
> Agree, I have removed the code in the CVS. I have also added a patch
> which can be applied until the next release. See http://
> www.tildeslash.com/monit/dist/monit-4.7.patch01.README and http://
> www.tildeslash.com/monit/dist/monit-4.7.patch01
> 
> --
> Jan-Henrik Haukeland
> Mobil +47 97141255
> 
> 
> 
> --
> To unsubscribe:
> http://lists.nongnu.org/mailman/listinfo/monit-general





reply via email to

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