Summarize the contents of a syslog log file


This program summarizes the contents of a log file written by syslog, by displaying each unique (except for the time) line once, and also the number of times such a line occurs in the input. The lines are displayed in the order they occur in the input.

OPTIONS

-q, –quiet Don’t output anything, unless there were unmatched lines.
-i filename, –ignore=filename Read regular expressions from filename, and ignore lines in the logfiles that match them.
-s filename, –state=filename Read state information from filename. The state contains information about the already reported parts of a log file, and prevents syslog-summary from reporting the same things many times. This is useful when syslog-summary is run from crontab every hour. The file is created, if it doesn’t exist already.

2008-01-16-065754_1280x800_scrot.png



Subscribe without commenting


Leave a Reply

Note: Any comments are permitted only because the site owner is letting you post, and any comments will be removed for any reason at the absolute discretion of the site owner.