Web Hosting Talk







View Full Version : Logs eating up a lot of space ALMOST 1 GB!


fshost
05-24-2003, 02:57 AM
In my tmp folder (think that's what it was) I have about a Gigabyte full of logs, what do I do with them, just delete the logs themselves, or what? I don't want to lose it all, so I think I will back it up to my harddrive.

Knogle
05-24-2003, 03:08 AM
I think you can prune the older ones.. after a while, you don't really need to keep the logs. They just become a waste of space.

Otherwise you can download it all onto your local harddrive, and burn it onto a CD. :D

fshost
05-24-2003, 03:31 PM
Thank You

Rich2k
05-24-2003, 05:07 PM
Although for busy sites it's quite common to eat up 250meg in a day

ffeingol
05-24-2003, 05:51 PM
fshost,

What kind of logs?

Frank

kidfive5
05-24-2003, 05:56 PM
I would delete the logs older then a month.

Andrej
05-24-2003, 08:43 PM
I think it'd be a good idea to DL them onto your HD, compress them (maximum) and burn 'em onto CDR. You never know when they'll be handy.

kidfive5
05-24-2003, 08:47 PM
It's a good idea, but most of the time logs are rather useless.

hololi
05-29-2003, 07:34 PM
my $0.02

assuming you are talking about transfer logs from websites ?

if so...
you should be "rotating" them regularly (daily,weekly...) depending on how busy your site(s) are.


I would copy them and gzip the copy (as transfer logs are text files they really compress a lot with gzip)

NOTE : before you gzip the copy you could also run a webstats program over them and produce statistics reports for you/your clients..anyway..

once copied I burn them on to CD as already recommended or at least store them on a different machine (in disaster recovery terms having them all on the one machine is a "single point of failure")

If they are transfer logs from apache you are talking about.. I have written a neat script (bash) that will copy, compress the log files and flush them.

flushing them is really cool as it nukes the contents of the log file but does not mess with the file descriptor. Huh ? I hear you say... this means you can flush the files on a running apache server without the need for bouncing the server.

cronning this type of script then lets you forget all your huge log file worries.

let me know if you want the script and I'll post it somewhere for you ...

good luck
hololi

fshost
05-29-2003, 09:51 PM
I'm going to ask the tech, managed server :D