How to Find Highest Disk Consuming Files and Directories in Linux?

Below are the list of some commands tat can help you to find highest disk consuming files and directories in Linux.

#1. By Using du command

You can use du command with in the following ways.
  • du -a /home | sort -n -r | head -n 5
  • du -hs * | sort -rh | head -5
  • du -Sh | sort -rh | head -5

#2. By Using find command

find command can also be used to list highest disk consuming files and directories.
  • find -type f -exec du -Sh {} + | sort -rh | head -n 5
  • find -type f -size +50M
  • find -type f -size +50M -exec ls -alh {} \; | sort -nk 5

#3. By Using ls command

You can execute ls command  with the argumenst as mentioned below.
  • ls -alhS
  • ls -lhtr
That's It !
Check out the blog to read in-detailed procedure for all the commands.
  • command to get hisghest consuming files and directories on serve, find highest disk consuming files and directories in Linux, find large files and directories using du command, Command that help you to get large files and directories on serv, find large files and directories using ls command, find large files and directories using find command, find large files and directories in Linux
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

What are some Basic SSH commands?

List of some basic SSH commands are: ls – This command is used to list all files and...

How to connect to SSH?

Putty is an open-source SSH client used to connect to a remote server. This article describes how...

20 Basic Linux Commands and their Uses.

Following are the top 20 basic Linux Commands with Live Examples that would definitely help you...

How to Block/Unblock IPs from SSH?

You can easily block or unblock IPs  from SSH. #1. Block An IP Address from SSH First of all,...

How to install CpCleaner in cPanel through SSH?

CpCleaner is a cPanel plugin created to give cPanel users the option to clean junk files that...