Display the size of files in blocks from largest to smallest.
$ ls -s | sort -nr | more |
sort -nr |
Sorts the list of files by block size from smallest to largest. |
In the following example, wtmpx and lastlog are the largest files in the /var/adm directory.
$ cd /var/adm $ ls -s | sort -nr | more 320 wtmpx 128 lastlog 74 pacct 56 messages 30 wtmp 6 utmpx 2 utmp 2 sulog 2 sa 2 passwd 2 log 0 spellhist total 624 |