DZone Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Snippets has posted 5883 posts at DZone. View Full User Profile

Check Directory/dir/file Size In Linux

12.09.2008
| 104755 views |
  • submit to reddit
        

#check partition sizes
df -h

#check directory size
du -s -h /var/log/

#check every directory and file sizes under a dir.
du -s -h /var/log/*

#check individual size size
du -s -h /var/log/lastlog