1> to display disk usage for a directory tree and every subtreeDu/home/linuxThis shows the number of disk blocks in the/home/linux directory and each of its subdirectories. 2> to display the disk usage of a tree and each of its subtrees in 1024-byte unitsdu-k/home/linuxThis shows the number of 1024-byte disk blocks in the/home/linux directory and each of its subdirectories. 3> Displays the disk usage of a directory tree and each of its subtrees in megabytesdu-m/home/linuxThis shows the number of MB disk blocks in the/home/linux directory and each of its subdirectories. 4> Displays the disk usage of one directory tree and each subtree in gigabytesdu-g/home/linuxThis displays the number of GB disk blocks in the/home/linux directory and each of its subdirectories. 5> View the size of all directories and subdirectories under the current directory:du-h."." Represents the current directory. can also be replaced by a clear path-H means to display the human form of K, M and G6> View the size of the user directory under the current directory, and do not want to see other directories and their subdirectories:Du-sh User- s means that a summary value is listed onlydu-h--max-depth=0 User--max-depth=n means that only deep into the nth-level directory, where set to 0, means not to go deep into subdirectories. 7> Lists the size of all directories and files under the user directory and its subdirectories:Du-ah User-a means including directories and files8> lists the size of the directory in the current directory that does not include the XYZ string:du-h--exclude= ' *xyz* '9> want to get more information about the user directory and the size of subdirectories on one screen:du-0h User0 (bar 0) indicates the information for each directory listed, not wrapping, but outputting the information of the next directory directly. 10> only shows all disk usage for one directory treedu-s/home/linux11> View each folder size:du-h--max-depth=1
How to use Linux system commands < two >----du