> fd -HI . image2|wc -l
217773
> du -ks image2
3818440 # kilobytes
- scp 到优盘,文件系统格式是 hfs,电脑系统格式是 MacOS
> fd -HI . image2|wc -l
217773
> gdu -ks image2
3587536 image2 # kilobytes
> gdu -ks --apparent-size image2
3382593 image2 # kilobytes
- 文件数都是 217773 (fd: https://github.com/sharkdp/fd)
- gdu 是 GNU coreutils 套件的 du
- 问题 1: 一个 3818440 一个 3587536,是因为 du 程序还是文件系统格式不同导致结果不同?如何输出一致?
- 问题 2: apparent size 是啥?
print apparent sizes, rather than disk usage; although the apparent size is usually smaller, it may be larger due to holes in (`sparse') files, internal fragmentation, indirect blocks, and the like