Need a logging utility

H

healeyc

Somebody help . . .
I am looking for a utility that will read through a text log and use
the date in the line to determine if the line needs moved to an archive
log or not - leaving the most recent days (weeks, or months) of log
entries in the current log. Take the following for an example:

[06/14/2006 00:00:10] xxxxxx xx 99.99 xxxx
[06/14/2006 00:00:12] xxxxxx xx 99.99 xxxx
[06/14/2006 00:00:12] xxxxxx xx 99.99 xxxx
[06/14/2006 00:00:13] xxxxxx xx 99.99 xxxx
[06/14/2006 00:01:13] xxxxxx xx 99.99 xxxx
[06/14/2006 00:01:15] xxxxxx xx 99.99 xxxx
[06/14/2006 00:01:16] xxxxxx xx 99.99 xxxx
:::
[07/03/2006 14:59:43] xxxxxx xx 99.99 xxxx
[07/03/2006 14:59:48] xxxxxx xx 99.99 xxxx
[07/03/2006 15:00:45] xxxxxx xx 99.99 xxxx
[07/03/2006 15:00:45] xxxxxx xx 99.99 xxxx
[07/03/2006 15:00:50] xxxxxx xx 99.99 xxxx


I need to move everything older than lets say two weeks from the
CPUHistory.log file and append it to (or create) the
old-CPUHistory.log.

It would be nice if there was a GUI and a config file that will
remember the dozen or so different log files and how I want to archive
them. What I mean is that some of them such as CPU detail I only want a
couple of weeks in the current file where as in disk space I could want
a couple of months in the current log file.

Additionally I would love to see a way to go through the archive file
and consolidate either by average or by removing duplicate results such
as Disk space if the space is the same for a few weeks only keep the
line when it changes. However this is not my primary need just a
desired feature.

Even if there is a cmd line version I can write batch files to use it
just fine. I have tried to write some VB myself but I suck at that and
cannot imagine that there is not already a better tool available. My VB
version was a tad (OK - very darn slow) slow as I go through line by
line and not read the entire file of 250,000+ lines in and use an array
to find the cut off and such.

Any one that knows of a great utility that can do this I would be most
appreciative!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top