Cobraiti
asked on
Filesystem full in Ubuntu
Filesystem Size Used Avail Use% Mounted on
/dev/cciss/c0d0p1 130G 130G 0 100% /
none 7.9G 232K 7.9G 1% /dev
none 7.9G 24K 7.9G 1% /dev/shm
none 7.9G 112K 7.9G 1% /var/run
none 7.9G 0 7.9G 0% /var/lock
none 7.9G 0 7.9G 0% /lib/init/rw
/dev/sdb1 250G 176G 75G 71% /srv
Hi I don't know where to look for the file or dir which is causing the local filesystem to be at 100%
I've checked using df -hs of each dir under root but nothing comes up
Is there a way to check and list files over a certain size ?
Help !!!
Thanks
/dev/cciss/c0d0p1 130G 130G 0 100% /
none 7.9G 232K 7.9G 1% /dev
none 7.9G 24K 7.9G 1% /dev/shm
none 7.9G 112K 7.9G 1% /var/run
none 7.9G 0 7.9G 0% /var/lock
none 7.9G 0 7.9G 0% /lib/init/rw
/dev/sdb1 250G 176G 75G 71% /srv
Hi I don't know where to look for the file or dir which is causing the local filesystem to be at 100%
I've checked using df -hs of each dir under root but nothing comes up
Is there a way to check and list files over a certain size ?
Help !!!
Thanks
As root
find / -type f -size 1G
Will report whatever file size bigger than 1GB
find / -type f -size 1G
Will report whatever file size bigger than 1GB
Woo, should be
find / -type f -size +1G
or
find / -type f -size +100M # whatever bigger than 100MB
find / -type f -size +1G
or
find / -type f -size +100M # whatever bigger than 100MB
> Is there a way to check and list files over a certain size ?
find / -type f -size +100M -exec du -sh {} \;
It will list the file list which over 100MB and the file size.
For example
105M /var/log/messages
1.2G /var/log/btmp
find / -type f -size +100M -exec du -sh {} \;
It will list the file list which over 100MB and the file size.
For example
105M /var/log/messages
1.2G /var/log/btmp
ASKER
Thanks for the info Is there anyway to exclude the /srv dir from the 'find'
As it's finding everything in my srv which is a mounted drive
As it's finding everything in my srv which is a mounted drive
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you very much for your assistance. :)
du -xsk /* | sort -n
to check which directory using the most disk space, say /var for example, then
du -xsk /var/* | sort -n
Usually, some log files under /var/log and /tmp.