Sunday, January 13, 2013

HOW TO FIND FILE THAT CAUSE FILE SYSTEM FULL

Thanks to http://www.unix.com/solaris/160743-root-directory-full.html and http://www.unix.com/solaris/48675-solaris-10-proc-making-filesystem-full.html, because from this site I can found file that cause my file system full. Below is some explanation problem and solving.

I have file system like below. / and /platform/... file system almost reached 100 %.



I am curious what is root cause of this growth.
After searching from google, I find 2 site that give me the clue ( as I mentioned above)  

Method 1 :
Check files that have more that 100 MB
bash-3.00# find / -xdev -type f -size +100000000c -exec ls -lh {} \;

Method 2 :
Sort all files   bash-3.00# du -dok / | sort -rn  > list.txt
View list.txt and check file size on the top.
bash-3.00# more list.tx










After find the file and make sure this file is not use by another process, then I make this file size to zero (example by below command)
bash-3.00# cat /dev/null > dev_ccmsping.old

There are also another useful command
bash-3.00# du -sk * |sort -rn |head
You can sort size of  file / folder below your work directory by this command

I hope all these command can help you too :)

No comments:

Post a Comment