Current time: 04-13-2025, 07:04 AM Hello There, Guest! (LoginRegister)


Post Reply 
How to deal with log storage/rotation
Author Message
aseques Offline
Member
*****
Dev Team

Posts: 330
Joined: May 2008
Reputation: 4
Post: #1
How to deal with log storage/rotation
Keeping proper logs is really important when looking for issues on your server. Usually is the only way you can find attacks or broken stuff. Also it's mandatory by law to keep this information for at least six months in Europe.

Here I'll summarize the issues and the best practices about log keeping (in my opinion) and open bugs about what can be improved.
Feel free to report any issues you find or corrections about this.

The most important logfiles are:
.- The logs used for http accounting are the ones /var/log/apache2/*.log (cannot use dateext)
.- The logs used for ftp accounting are the ones in /var/log/proftpd/ftp_traff.log (cannot use dateext)
.- The per user logs from apache are on /var/log/apache2/users/*
.- The mail logs are on /var/log/mail.*

More information about the logs: here

Known issues

Create a script to handle the old log archive
There is a big amount of logs in a used server. There should be a crontab that could handle the catalogation of those logs. There's a ready to use patch in ticket 2577
Ticket 2577


Updates
improvements in logrotate
The logs that are interesting to be keeped should change the name scheme into something more clear (specifying date). Rotation should be done daily to help in high traffic sites. The logs should be keeped for longer time.
Ticket 2570
Fixed on r3838
(This post was last modified: 06-10-2011 11:16 PM by aseques.)
05-26-2011 06:20 PM
Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
How to deal with log storage/rotation - aseques - 05-26-2011 06:20 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)