[clue] seeking advice cleaning up root

Raymond DeRoo rderoo at deroo.net
Sun Mar 20 10:17:31 MDT 2011


>>> Bit of an adventure, not really sure what happened, but I broke my laptop
>>> somehow by filling root, and removing /var/cache/apt freed up a GB and it's
>>> working again.   That said, I would still appreciate advice on how to go
>>> about putting my root partition on a diet, preferably so this doesn't happen
>>> again.  Given my druthers I'd rather it stay below 8GB

Being cheap on / space usually will cause issues later on. Disk is cheap, yes even in laptops. ( Ok, maybe not SSD ). A good partitioning plan and using LVM can go a long way in helping with disk management. I would also recommend ( for a laptop ) avoid file system like XFS which can be grown, but not shrunk ( easily, for those about ready to tell me about using disk images to resize XFS ).

> If you have a database (e.g. mysql) on the box, you can move
> /var/lib/<mysql, etc.> out of / and replace it with a symlink. /tmp
> and /var/tmp are also good candidates for moving.

Relocating MySQL, Postgres and other RDBMS data directory and then symlinking it is nearly always a bad idea and strongly discouraged. If you need to move it from the default location ( which it should be moved from /var/lib ) then edit the appropriate config file and change the datadir accordingly.

.r



More information about the clue mailing list