du command to Check file/folder disk usage in Linux

Windows Articles

How to install SQLite on OpenSUSE 15.2 / 15.1?

There are many good database management systems, but they are not all the same. And the fact that they are not, means...

How to detect port scanning and private IP access with Behave

Hello! Security when surfing the internet is a very serious issue. Consequently, the precautions we take are very important. Moreover, web browsers...

How to install LAMP on OpenSUSE 15.2 / 15.1?

It is increasingly common to find small companies that decide to use the SUSE ecosystem for their servers. It's an unsurprising decision because OpenSUSE...

How to use Mytop on Linux?

We already know that both MySQL and MariaDB are among the most popular database managers out there. They have earned this with...

How to activate the automatic screen saver in Windows 10

Hello! Undoubtedly the time we spend in front of a computer has grown lately. In fact, in these times of pandemic, more...
Muhammad Nabeel
Muhammad Nabeel
Network and System Administrator

Linux du (Disk Usage) is a Unix/Linux command. It used to check disk usage of files and directories on Linux system. There are many options of du commands to get different outputs which we use in below examples.

Check Directory Disk Usage Summary

So, below command is used to get the summary of disk usage of /boot directory. Its also unclude sub-directory summary.

du /boot
disk usage summary of /boot directory.

If you want to see a grand total disk usage of a directory, use below command where / should be your desired directory name.

du -s /boot
See only grand total space using by /boot directory.

Check disk usage in human readable form

Now we will see disk usage of /boot directory in human readable from with grand total.

du -hs /boot
Check grand total disk usage space of /boot directory in human readable form.

Check Disk Usage of Directories with files.

what if you wanna see that how much space is using by both, files and folders. to check that simply run below command

du -ah /boot

See Disk usage with Time

If you want to see total usage of a directory with it last modification time and date, then run following command

du -h --time /boot

Show disk space usage in KB

Simply run below command to see disk usage of a directory in kilobytes

du -k /boot

List space Usage in MB

du -mh /boot

Read manual pages using command “man du” for more information.

More articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest article

How to install SQLite on OpenSUSE 15.2 / 15.1?

There are many good database management systems, but they are not all the same. And the fact that they are not, means...

How to detect port scanning and private IP access with Behave

Hello! Security when surfing the internet is a very serious issue. Consequently, the precautions we take are very important. Moreover, web browsers...

How to install LAMP on OpenSUSE 15.2 / 15.1?

It is increasingly common to find small companies that decide to use the SUSE ecosystem for their servers. It's an unsurprising decision because OpenSUSE...

How to use Mytop on Linux?

We already know that both MySQL and MariaDB are among the most popular database managers out there. They have earned this with...

How to activate the automatic screen saver in Windows 10

Hello! Undoubtedly the time we spend in front of a computer has grown lately. In fact, in these times of pandemic, more...