[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [hobbit] system log and application log monitoring
- To: hobbit (at) hswn.dk
- Subject: Re: [hobbit] system log and application log monitoring
- From: "Jeff Newman" <jeffnewman75 (at) gmail.com>
- Date: Fri, 2 Jun 2006 11:03:52 -0500
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=S1QJnhuBpRS5njUYjlHMyNp0bjiTf4pNQ7CS6CsCYLwkQMwMJ7gBhrqMHgQH1dYeQwIJDFTH1KDMFFSonaCd1OqW30RhHVH+ZUHiiJASobdgAJ1pzDhLlji/zPsIHmZfsSwjXB8G59jiz9EHQqlcJeo0uR0xa5eo9GwRMbAeD5w=
- References: <1148232589.4470a38db8528@www.qalpit.com> <20060528160730.GG14589@hswn.dk>
Henrik,
Is there a facility already in place, or a way to graph the number of "hits"
returned by a pattern match for a log file?
For instance:
I am checking xyz log file for the word "wrap" It would be *very* useful to have
a graph that shows the number of times that word showed up between the previous
check and the current check.
This could be very useful to illustrate, say, a disk dying (one blip
of a bad read or something would be one thing, but looking at a graph
over time that shows 1 blip one week, 10 the next, and 20 the week
after that would indicate the disk was almost dead) etc...
Right now, the only way I have to do this is with a client side script that
runs in a constant loop:
while true; do
NUM=`grep "Buffer wrapped" /quotes/env/errlog | wc -l | sed 's/ *//g'`
if [ $NUM -gt $INITIALNUM ] ; then
WRAP_NUM=`expr $NUM - $INITIALNUM`
$BB $BBDISP "status $MACHINE.wraps green `date`
`echo "wraps:$WRAP_NUM"`
"
INITIALNUM=$NUM
else
OKNUM=0
$BB $BBDISP "status $MACHINE.wraps green `date`
`echo "wraps:$OKNUM"`
"
fi
-Jeff
On 5/28/06, Henrik Stoerner <henrik (at) hswn.dk> wrote:
On Sun, May 21, 2006 at 07:29:49PM +0200, Olivier Beau wrote:
>
> well.. i was glad to find OS log files definitions in client-local.cfg
> Could there be basic OS pattern definitions in hobbit-client.cfg's DEFAULT ?
You'll have to contribute some, then. I don't really know what people
are looking for in their logfiles.
> next step: application log monitoring
> let's say i have 100 servers (differents OS of course) running mysql, and i want
> to follow "ended" in /var/log/mysqld.log
> ->setting up 100 entries in client-local.cfg doesn't seem great, could there be
> some kind of grouping in client-local.cfg (PAGE actually..) ? (i guess this
> would required to processing client-local.cfg before transferring to the clients..)
Welcome to the world of configuration "classes".
Step 1: Put a "CLASS:mysqlservers" on those hosts in bb-hosts.
Step 2: Put a section in your client-local.cfg file with
[mysqlservers]
logfile:/var/log/mysql/status.log
Step 3: Configure hobbit-clients.cfg for these logfiles.
Only problem is that you'll need todays snapshot for this to work.
Regards,
Henrik
To unsubscribe from the hobbit list, send an e-mail to
hobbit-unsubscribe (at) hswn.dk