Showing directory sizes in Linux

7 07 2009

If there is no VNC Server available to manage your server with GUI Facility, then terminal is the fastest way to solve it.

Command for showing directory sizes in Linux:

$user@machine /home/gibran>du -h
This will show you each subdirectory sizes in directory /home/gibran with human readable ( -h ) fiturs, something like this:
48K ./images
328K ./language
15M ./captcha
48K ./templates/default
52K ./templates
15M .

If you want to summarize your current active directory, here they are:
$user@machine /home/gibran> du -sh

This will show you summarize ( -S) all files and directory in /home/gibran, like this one:
15MB .
in above examples, we can see that /home/gibran has 15MB totals directory and files.


Tindakan

Information

Tinggalkan komentar