How can I check the remaining disk space in Linux?

In Linux system, you can check the remaining space on the hard drive by using the df command. Here are some common options when using the df command:

  1. Check the usage of all file systems, including remaining space, used space, and total space on the hard drive.
df
  1. Display disk usage in human-readable format using units like G and M.
df -h
  1. df -a: Display usage information for all file systems, including special and temporary file systems.
df -a
  1. df -T: displays the types of file systems.
df -T
  1. df -i: displays the inode usage of the file system.
df -i
  1. Show only local file systems, excluding NFS and other network file systems.
df -l
  1. Exclude the specified type of file system using df -x, for example, exclude tmpfs and devtmpfs file systems.
df -x tmpfs -x devtmpfs
  1. df -t : display only the specified type of filesystem, such as showing only ext4 filesystems.
df -t ext4

By using the commands and their options mentioned above, you can easily check the remaining space on the hard drive in a Linux system.

bannerAds