Forum Moderators: DixonJones

Message Too Old, No Replies

Log Files outta hand

(: help 4 day log = 491 megs

         

EliteWeb

12:41 am on Mar 14, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Wow, I love statistics and such but this log file is just for one site and its 491 megs worth of log within 4 days!

It seems I wont be able to even check the whole month, I dont have the hard drive space to keep on with this.

Any suggestions.

ls -lah access_log
491M Mar 13 16:41 access_log

Air

12:48 am on Mar 14, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Use "logrotate" to spawn a new log after a set amount of time or when the log reaches a certain size. The rotated log can be compressed with the last log in the rotation being archived or deleted.

EliteWeb

12:55 am on Mar 14, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Unless logs can be compressed to like 90% of the origating space then hehehe.

ggrot

1:19 am on Mar 14, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Actually, logs of that size could probably be compressed down to like 5-10% of the original size with some of the more serious compression routines available. They are plain text and have alot of redundancy in them.

ktmatu

7:00 am on Mar 14, 2002 (gmt 0)

10+ Year Member



bzip2 [sources.redhat.com] is an excellent tool for compressing log files. It's slower than the standard gzip tool, but the compression ratio is much better.

SmallTime

8:32 am on Mar 14, 2002 (gmt 0)

10+ Year Member



quick question on deleting log files (on accounts where I don't have shell access, log file in my directory on virtual host, unix) Can I just delete the file, and will it automatically start a new one?, or rename the old one, create a new file? how exactly to I get a fresh start?