Listing files by size
There are lots of ways to list files and sort by their size with the help of pipe operator, for example:
ls -l | sort -n -k 5
But ls command already has builtin support for this:
ls --sort=size -l
you can reverse the list with -r option:
ls --sort=size -lr
or you may add -h (human-readable) parameter for good looking:
ls --sort=size -lrh
- 0 Comment
- Murat Demirten
- 24 Jun 2008, 15:34
-
You must be login first or sign-up for an account to post comments.
Maybe you should look at these also:
USERBOX
CATEGORIES
MOST READED TODAY
- Creating splitted rar archive files
- XFS Filesystem has duplicate UUID problem
- Converting MAC dfonts to TrueType
- Changing time in Linux
- Recovering mysql root password
- Recovering Root Password
- Network interface status with mii-tool
- dropbear rsa key problem
- Calculating SHA Checksums
- Passwordless sudo setup
LAST ADDED
- Routing packets back from incoming interface
- Users with /bin/false shell to login on vsftpd
- Redirecting TCP ports with redir
- Assembly code of a C code
- Network interface status with mii-tool
- dropbear rsa key problem
- Displaying disk io statistics
- Disabling ssh password authentication
- Creating splitted rar archive files
- Creating self-extracting zip archives for both Linux and Windows
