FW: log rotation - how many files are kept?

Wheeler, JF (Jonathan) J.F.Wheeler at rl.ac.uk
Thu Jan 18 12:49:42 CET 2007


-----Original Message-----
From: nagios-users On Behalf Of Stijn Gruwier
Sent: 18 January 2007 07:37

> I'm aware that nagios is able to copy the nagios.log file to the 
> archives directory on an hourly/daily/weekly/monthly basis. It seems 
> that nagios keeps that files forever since I've got 11 archived weekly

> logs. But the word 'rotation' suggests that at some time the old ones 
> are removed and replaced by newer logs. Is this the case? I searched
the 
> mailing list and the documentation but I couldn't find the answer.

I also came across this problem and have written a script to organise
our archived logs.  At present I run it manually, but it could be a cron
script.  What is does is to keep up to 180 logs (1 per day for 6
months), but all but most recent 5 are zipped.  The numbers in the
previous sentence are parameters at the head of the script.
Unfortunately the form of the name of the archived logs is not suitable
for processing with standard logrotate.  I am happy to let others use
this script if a) no one has anything better, and b) if someone can tell
me where to submit it.

Jonathan Wheeler
e-Science Centre
Rutherford Appleton Laboratory

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list