disqus4u Latest Questions

How can I check for the available disk space on a Linux system?

Global Intel
Begginer

What is the command to check for the available disk space on Linux?

Related Questions

  1. There are several ways to check for the available disk space on Linux systems. These include:

    Using the df command

    Run the the df command on your Linux terminal

    df -h

    Here is the sample output you will see:

    Filesystem Size Used Avail Use% Mounted on
    /dev/sda1 20G 8.2G 10G 46% /
    tmpfs 2.0G 0 2.0G 0% /dev/shm
    /dev/sdb1 100G 25G 75G 25% /home
    /dev/sdc1 250G 180G 70G 73% /data

    This output lists the various disk partitions with their corresponding storage usages. All Linux disk partitions are located in the /dev/ directory.

    Using the du command

    Another way to check the disk space on Linux is to use the du command:

    du

    When you run this command, here is the sample output you will see:

    4.0K ./Documents
    8.0K ./Downloads
    16K ./Pictures
    24K ./Music
    36K ./Videos
    48K ./Desktop
    4.0K ./Templates
    76K ./total
    

    It’s important to note that each line represents the disk usage in kilobytes (KB) for a specific directory or file.

    I recommend that you read this article to help you understand disk management on Linux

Leave an answer

Leave an answer