Linux df command All In One

发布时间 2023-03-31 23:45:50作者: xgqfrms

Linux df command All In One

df

disk free

$ df --help

用法:df [选项]... [文件]...
Show information about the file system on which each FILE resides,
or all file systems by default.

必选参数对长短选项同时适用。
  -a, --all             include pseudo, duplicate, inaccessible file systems
  -B, --block-size=SIZE  scale sizes by SIZE before printing them; e.g.,
                           '-BM' prints sizes in units of 1,048,576 bytes;
                           see SIZE format below
  -h, --human-readable  print sizes in powers of 1024 (e.g., 1023M)
  -H, --si              print sizes in powers of 1000 (e.g., 1.1G)
  -i, --inodes		显示inode 信息而非块使用量
  -k			即--block-size=1K
  -l, --local		只显示本机的文件系统
      --no-sync		取得使用量数据前不进行同步动作(默认)
      --output[=FIELD_LIST]  use the output format defined by FIELD_LIST,
                               or print all fields if FIELD_LIST is omitted.
  -P, --portability     use the POSIX output format
      --sync            invoke sync before getting usage info
      --total           elide all entries insignificant to available space,
                          and produce a grand total
  -t, --type=TYPE       limit listing to file systems of type TYPE
  -T, --print-type      print file system type
  -x, --exclude-type=TYPE   limit listing to file systems not of type TYPE
  -v                    (ignored)
      --help		显示此帮助信息并退出
      --version		显示版本信息并退出

所显示的数值是来自 --block-size、DF_BLOCK_SIZE、BLOCK_SIZE 
及 BLOCKSIZE 环境变量中第一个可用的 SIZE 单位。
否则,默认单位是 1024 字节(或是 512,若设定 POSIXLY_CORRECT 的话)。

The SIZE argument is an integer and optional unit (example: 10K is 10*1024).
Units are K,M,G,T,P,E,Z,Y (powers of 1024) or KB,MB,... (powers of 1000).

FIELD_LIST is a comma-separated list of columns to be included.  Valid
field names are: 'source', 'fstype', 'itotal', 'iused', 'iavail', 'ipcent',
'size', 'used', 'avail', 'pcent', 'file' and 'target' (see info page).

GNU coreutils 在线帮助:<https://www.gnu.org/software/coreutils/>
请向 <http://translationproject.org/team/zh_CN.html> 报告 df 的翻译错误
完整文档请见:<https://www.gnu.org/software/coreutils/df>
或者在本地使用:info '(coreutils) df invocation'
pi@raspberrypi:~/Desktop $ 

demos

$ df -h
文件系统        容量  已用  可用 已用% 挂载点
/dev/root        29G  6.4G   22G   23% /
devtmpfs        243M     0  243M    0% /dev
tmpfs           248M     0  248M    0% /dev/shm
tmpfs           248M  9.7M  238M    4% /run
tmpfs           5.0M  4.0K  5.0M    1% /run/lock
tmpfs           248M     0  248M    0% /sys/fs/cgroup
/dev/mmcblk0p1  253M   51M  202M   21% /boot
tmpfs            50M     0   50M    0% /run/user/1000
pi@raspberrypi:~/Desktop $ 

$ df -Th
文件系统       类型      容量  已用  可用 已用% 挂载点
/dev/root      ext4       29G  6.4G   22G   23% /
devtmpfs       devtmpfs  243M     0  243M    0% /dev
tmpfs          tmpfs     248M     0  248M    0% /dev/shm
tmpfs          tmpfs     248M  9.7M  238M    4% /run
tmpfs          tmpfs     5.0M  4.0K  5.0M    1% /run/lock
tmpfs          tmpfs     248M     0  248M    0% /sys/fs/cgroup
/dev/mmcblk0p1 vfat      253M   51M  202M   21% /boot
tmpfs          tmpfs      50M     0   50M    0% /run/user/1000
pi@raspberrypi:~/Desktop $ 


image

duf

https://github.com/muesli/duf

(? 反爬虫测试!打击盗版⚠️)如果你看到这个信息, 说明这是一篇剽窃的文章,请访问 https://www.cnblogs.com/xgqfrms/ 查看原创文章!

refs

https://www.atatus.com/blog/df-command-in-linux-with-examples/

https://www.redhat.com/sysadmin/linux-df-command

https://www.geeksforgeeks.org/df-command-linux-examples/

https://www.tutorialspoint.com/unix_commands/df.htm

https://haydenjames.io/df-command-in-linux-with-examples/

https://linuxhint.com/linux-df-command-examples/

https://www.cyberciti.biz/faq/df-command-examples-in-linux-unix/



©xgqfrms 2012-2021

www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!

原创文章,版权所有©️xgqfrms, 禁止转载 ?️,侵权必究⚠️!