Dave's Brain

Browse - computer tips - linux find the largest files in a folder

Date: 2010jan27
OS: Linux

Q.  How I can find the largest/biggest files in a folder?

A.  Use the -S option for ls that sorts by size.  I also like to use the
-h option that displays sizes in human-friendly format.  Then pipe
it to head which will display the top ten:

	ls -lSh | head

What this info useful to you? You can donate to say thanks

Add a comment

Sign in to add a comment
Copyright © 2008-2012, dave - Code samples on Dave's Brain is licensed under the Creative Commons Attribution 2.5 License. However other material, including English text has all rights reserved.