[Turn]DF command

Source: Internet
Author: User
Tags disk usage

DF command parameter function in Linux: Check the disk space consumption of the file system. You can use this command to get information about how much space the hard disk is taking up, and how much space is left.

Syntax:DF [ options ]

The various options for this command have the following meanings:

-a displays disk usage for all file systems, including 0 blocks of file systems, such as the/proc file system.

-H more Current disk space and usage to display in a more readable manner

-Theh parameter is the same as above, but the capacity is converted with 1000 instead of 1024 when formatting

-I displays the I node information, not the disk block.

-L shows the disk space usage of the local partition, if the server NFS the disk of the remote server, then the system displays the result after the filter NSF drive after adding-l to DF

-T displays the file system type.

-K is displayed as a unit

Example 1: list disk space usage for each file system

#DFFile System 1K-Block used available%mount point/dev/mapper/system-root20970876   283228  20687648    2% /Devtmpfs1963116      172   1962944    1% /Devtmpfs1963116  1030732    932384    -%/dev/SHM/dev/sda2104440    62560     41880    -% /Boot/dev/mapper/system-home41941756 26211736  15730020    the%/Home

Description

The 1th column of the output list of the DF command in Linux is the pathname of the device file that represents the file system (typically the partition on the hard disk), and the 2nd column gives the number of blocks (1024 bytes) that the partition contains, and the 3rd, 4 columns indicate the number of data blocks used and available respectively. Users may be surprised that 3rd, the sum of 4 column blocks is not equal to the number of blocks in the 2nd column. This is because each of the default partitions leaves a small amount of space for the system administrator to use. The administrator can log in and leave the workspace required to resolve the problem, even when the normal user space is full. The use% column in the list represents the percentage of normal user space used, even if the number reaches 100%, and the partition still leaves room for the system administrator to use. Finally, the mounted on column represents the mount point of the file system.

Example 2: List I node usage for each file system

 # df -aifilesystem inodes iused IFr EE iuse % mounted on /dev/mapper/system- 1310720  21794  1288926  2 %/ proc  0  0<                     /span>-/proc /dev/mapper/system-home  26214400  564785  25649615  3 %/home 

Example 3: List the file system types

DF -tfilesystem    Type   1K-blocks      used Available use% mountedon/dev/mapper/ system-root              ext3    10321208   3246400    6550520   %//dev/sda2 reiserfs      104376     41348     63028  40 %/boot/dev/mapper/system-home              ext3   206424760175039108   20899892  %/home

Description

The file system in this example is the ext3 type

Example 4: List file system disk space usage in an easier-to-read manner

DF -hfilesystem            Size  used Availuse% mountedon/dev/mapper/system-root                       9. 9G  3. 1G  6. 3G  %/tmpfs                  32G   8. 0K   32G   1/dev/shm/dev/sda2             102M   41M   62M   %/boot/dev/mapper/system-home                      197G  167G   20G   Home

[Turn]DF command

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.