[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Files piling up in /var/* directories



Gene Heskett wrote:
On Saturday 11 March 2006 06:52, Charles wrote:

I've noticed that I have files piling up in /var/cache, /var/log, and
/var/lib.  These three folders now have 100 mb of files in them.


Which of these must be present for the machine to run?  This is (at
the moment) a home machine; I don't *need* the  log files, but I
don't know what happens if I just delete the files in these three
directories.


That will eat your lunch. If logrotate is properly setup, those files will not grow beyond what they are as the old ones will be expunged

[snip]

With disc space a commodity thing, a 500 meg /var partition is

But if you have only one disc, it is a fungible commodity, and
reclamation is the way to go. I agree with logrotate. I use it,
and my /var looks like this...

# du -s /var/* | sort -gr
81528   /var/lib
77484   /var/cache
60184   /var/spool
5416    /var/log
1500    /var/tmp
1132    /var/www
128     /var/run
32      /var/yp
...

I don't think that 5MB is too big for my log files. I *do* wonder
about /var/spool, however. Hmm...

# du -s /var/spool/* | sort -gr
57904   /var/spool/up2date
2056    /var/spool/cups
164     /var/spool/mail
16      /var/spool/anacron
...

Yep, my package manager's the culprit. And...

# du -s /var/cache/* | sort -gr
76056   /var/cache/yum
1160    /var/cache/man
196     /var/cache/gstreamer-0.8
56      /var/cache/alchemist
...

Also my package manager.

unimaginable today, my /var/cache alone is 1,273,796 whatevers in du's default format. Which is not a big deal since /var is on /dev/hdd, a

That's way more than I would permit on my machine. I not only find
it imaginable that /var would be < 500MB, my /var is < 300MB. And
on occasion, I have cleaned out the package manager stuff (though
it tends to come back).

# df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/hda5              7633264   6147620   1097896  85% /
/dev/hda3                99075     24602     69358  27% /boot

Not everyone can afford hundreds of Gigs of disc space.
If disc is so cheap, will you buy me a new, larger drive?

[snip]

Mike
--
p="p=%c%s%c;main(){printf(p,34,p,34);}";main(){printf(p,34,p,34);}
This message made from 100% recycled bits.
You have found the bank of Larn.
I can explain it for you, but I can't understand it for you.
I speak only for myself, and I am unanimous in that!



Reply to: