no way to compare when less than two revisions
Differences
This shows you the differences between two versions of the page.
— | linux:shell_commands:du [2020/05/15 13:52] (current) – created - external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== du examples ====== | ||
+ | ===== How to Find Biggest Files and Directories in Linux ===== | ||
+ | # du -a /home | sort -n -r | head -n 5 | ||
+ | |||
+ | ===== Find Largest Directories in Linux ===== | ||
+ | # du -a | sort -n -r | head -n 5 | ||
+ | # du -hs * | sort -rh | head -5 | ||
+ | # du -Sh | sort -rh | head -5 | ||
+ | |||
+ | ===== Find Out Top File Sizes Only ===== | ||
+ | # find -type f -exec du -Sh {} + | sort -rh | head -n 5 | ||
+ | # find / | ||
+ | # find / | ||