Http://blog.csdn.net/newjueqi/article/details/7054582
The DF command is used to view the file system by disk partition in Linux. You can add parameters to view the remaining disk space. The command format is as follows:
DF-Hl
Display format:
File SystemCapacity in use available % mount point
FilesystemSize used avail use % mounted on
/Dev/hda245g19G24g 44%/
/Dev/hda1494 m19 m 450 m4%/boot
/Dev/hda64.9g 2.2g 2.5g 47%/home
/Dev/hda59.7g 2.9g 6.4g 31%/OPT
None1009 m0 1009 m0%/dev/SHM
/Dev/hda39.7g, 7.2g, 2.1g, 78%/usr/local
/Dev/hdb275g75g0 100%/
/Dev/hdb275g75g0 100%/
The preceding output is used as an example to indicate:
HD hard disk interface second hard disk (B), second partition (2), capacity is 75g, 75g used, available is 0, so the utilization is 100%, mounted to the root partition directory (/).
The following is an explanation of the relevant commands:
DF-Hl view the remaining disk space
DF-H: view the partition size of each root path
Du-SH [directory name] returns the directory size
Du-Sm [Folder] returns the total number of MB in this folder.
For more functions, run the following command:
DF -- Help
Du -- Help
View the partition of the hard disk # sudo fdisk-l
View IDE Hard Disk information # sudo hdparm-I/dev/hda
View stat hard disk information # sudo hdparm-I/dev/SDA or # sudo apt-Get install blktool # sudo blktool/dev/SDA ID
View remaining disk space # DF-h # DF-H
View the space occupied by the Directory # Du-HS directory name
The USB flash drive cannot be detached # Sync Fuser-km/Media/USB disk