df


 2017-02-02 1 minute read 0 Comments improve this post #command line | #linux

Summary

The df command may be used to check disk space.

Usage Examples

Display the output of df command in human readable format

The below command will print the sizes of a machine’s disks in human readable format (e.g. 1K, 234M, 2G)

# df -h

Display ouput in human readable format for local storage only (no remote storage such as NFS)

# df -h -l

Display inode information of the file system

# df -i

Find the top 20 inode consumers (of var):

# find /var -xdev -printf '%h\n' | sort | uniq -c | sort -k 1 -nr | head -n 20

List disk usage of all the file systems using ‘-a’

# df -a
# df -T
# df -k

 Categories: #linux


Tech tips and command line fu found within this dojo

 2023