Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Listing the largest files 1

Status
Not open for further replies.

FlashGorden

IS-IT--Management
Nov 8, 2001
22
EU
hi

I'm just a beginner in Unix (Solaris). I need to find the 3 largest files on the system and I used the following command;

ls -lR /| sort -n -r -k5|more -3

It almost works but the order is slightly wrong. The R command doesn't seem to work from root.

Any help would be appreciated.

Thanks.
 
What about ls -lR | sort +4n | tail -3

This will give the 3 largest files, with the largest last.

Greg.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top