Tip: Estimate File Space Usage
Friday, April 24th, 2009
Yet another tip that I use from time to time which I feel may be of benefit of others. It allows you to estimate file space used in a given directory by executing the ‘du‘ command via SSH (Secure Shell) / Telnet. For example, to display usage of ‘content’ directory (that contains two subdirectories: 1subdirectory and 2subdirectory) in human readable format (Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte):
du -sh *
Example output would be:
25.3M 1subdirectory
1.35G 2subdirectory
Refer to the du man page for further details regarding the ‘du‘ command: du command


