[ale] One-liner needed: log-rolling with a different spin

Mills John M-NPHW64 Jmills at motorola.com
Wed Jul 15 11:30:11 EDT 2009


ALErs -

I am accumulating a log file a bit faster than I would like, and only need to keep the most recent N lines (say, N = 100000) to examine in case of a crash. I want the log traffic to continue undisturbed while early lines are truncated.

I want to script this and run it as a 'cron' job to keep the file size manageable. I would prefer not to restart 'syslogd', mainly because it seems to me that should not be necessary.

Suggestions?

TIA.
 - Mills




-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.ale.org/pipermail/ale/attachments/20090715/371329fe/attachment.html 


More information about the Ale mailing list