Linux Commands To Check The Disk And Directory Information

Even though you can check the disk , directory information and usage using graphical user interface, it is important to now the terminal commands to check the disk information and usage of a Linux machine. In this tutorial am going to explain the important commands to check the disk and directory information in Linux systems.

There are two basic commands for the disk and directory. du and df. du deals with directories and df deals with disk.

du (abbrevation is disk usage): 

du command is used to determine the size of a directory. Lets say you have a directory demo and you have five directories named 1,2,3,4 and 5 inside demo. If your current directory is demo and if you use du it will show the size of folder inside it.

1. Displaying memory of directory in human readable form

2. Lets say you want to find out the total size of /Downloads folder , use the command below and last two lines will show the total size of the /Downloads folder .

If you just want to see the size use the tail command as follows to see the last two lines.

df (abbrevation is disk free):

1. df command gives the information about the disk space, mount point, used space, unused space and used space in percentage.

2. Getting the innode info.

Know More About Innodes 

3. Getting disk info in human readable form (Both Kb and Mb)

4.Getting all the info about file system and its type

5. Getting information about a specific file system type like ext3 or ext4

6. Getting information about the total memory of the disk.


How do I install the latest mongoDB database server and components in Redhat 7 or a centos 7 box? There are no…

Read more

Before understanding what hardlinks and softlinks are, you must have an idea about innodes in Linux Innode is related…

Read more

SSL (Secure Socket Layer) is a protocol , which establishes a secure connection between a web browser and the server so…

Read more

Internet is huge! Help us find great content


The Best Tutorials & Tips to Speedup Your DevOps Workflow.

Created by Bibin Wilson.