how to cleanup root file system
Hi everyone;
I have a problem that is probably simple, but have not yet found the answer on any forums or by Googling. First my system specs:
Tyan 2610 motherboard w/ 2 x PIII 933
4 gig PC133 SDRAM
1 x 5 gig hd (system)
4 x 500 gig hds w/ 3Ware 7500 controller set to RAID 5, (1.5 TB) mounted as /home
CentOS 5.3 running my smb and nfs mounts
My problem is that I have run out of space on my / (root) file system, (the 5 gig). Since I am planing to rebuild my file server with larger hard drives, (2 x's 60 gig SATA's set to RAID 1, 6 x's 1.5 TB at RAID 5), within the next 2 months, I would like to try to clean out any unneeded crap rather than adding a hard drive and expanding my root file system. I have done the following:
Removed old unused kernels
cleaned up /var/log/
cleaned up /tmp
I have tried to check my disk space usage with the following commands: (output included)
[root@hydra]$ df -h
\Filesystem Size Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
3.9G 3.2G 490M 87% /
/dev/sda1 99M 13M 82M 14% /boot
tmpfs 1.5G 0 1.5G 0% /dev/shm
/dev/sdb1 1.4T 1.1T 340G 76% /home
[root@hydra]$ du -ks /var/* | sort -nr | head
75556 /var/cache
60136 /var/lib
31296 /var/log
30364 /var/clamav
18380 /var/spool
9640 /var/www
224 /var/run
84 /var/webmin
36 /var/lock
32 /var/empty
[root@hydra /]$ du --max-depth=1 -x -h /
8.0K /selinux
0 /misc
8.0K /mnt
78M /lib
0 /net
0 /proc
128M /etc
8.0K /media
132M /opt
5.3M /root
194M /var
2.7G /usr
84K /tmp
29M /sbin
8.0K /srv
4.0K /home
0 /sys
7.2M /bin
2.0K /boot
16K /lost+found
0 /dev
3.2G /
Going into my /usr and running du --max-depth=1 -x -h / gives me this:
[root@hydra usr]$ du --max-depth=1 -x -h /
8.0K /selinux
0 /misc
8.0K /mnt
78M /lib
0 /net
0 /proc
128M /etc
8.0K /media
132M /opt
5.3M /root
194M /var
2.7G /usr
84K /tmp
29M /sbin
8.0K /srv
4.0K /home
0 /sys
7.2M /bin
2.0K /boot
16K /lost+found
0 /dev
3.2G /
I have gone through /var/cache and and /var/log and deleted anything that I felt would not break my OS by deleting, I did not touch /usr yet, (I want to do more research before tampering there!!), but I am still getting this error:
[root@hydra VM Ware]$ rpm -ivh VMware-server-2.0.2-203138.i386.rpm
Preparing... ########################################### [100%]
installing package VMware-server-2.0.2-203138.i386 needs 233MB on the / filesystem
Does anyone have any suggestions on how I can clean up about 300 MB more of disk space?
Thanks
zog
Last edited by zogthegreat; 01-31-2010 at 05:09 PM.
|