monit-dev
[Top][All Lists]
Advanced

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

Preliminary log matching support


From: Christian Hopp
Subject: Preliminary log matching support
Date: Mon, 1 Aug 2005 14:37:01 +0200 (CEST)

Hi!

Good news everyone...

I have made a first version for "logfile matching".  It lacks
documentation and some verbose logging issues.  But it could be used
for testing.

Usage:

check file foobar.log with path /tmp/foobar.log
        if match "foo.*bar" then alert

You need regex support in order to use this (without regex it makes no
sense to me).  The initial read point is the file end. Upon inode
change or filesize reduction the read counter is reseted to zero.  In
case a file changes (increases) and is moved, the rest of the old one
is gone and is not matched!  Only lines with "\n" or lines with the
length of STRLEN are matched.

Please have a look at it and give me some feedback for further changes
or wishes.  As always the patch needs to applied agains todays CVS.

Bye,

Christian

--
Christian Hopp                                email: address@hidden
Institut für Elektrische Informationstechnik             fon: +49-5323-72-2113
TU Clausthal, Leibnizstr. 28, 38678 Clausthal-Zellerf.   fax: +49-5323-72-3197
                             pgpkey: https://www.iei.tu-clausthal.de/pgp-keys/

Attachment: monit_logmatch_prelim1.patch
Description: Text document


reply via email to

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