du の出力が間違っていますか?

du の出力が間違っていますか?

私の du コマンドが混乱しているようです。

% du -shc DIR ...
...
6123941496      total

% du -shc DIR ...
...
6.1G    total

% du -sc --si DIR ...
...
6.6G    total

スプレッドシートで結果を入力して再確認してみましLANG=Cた。-h はすでに 1000 の累乗 (--si) を使用して出力しているようですが、--si は間違った答えを返します。正しい答えは、-h の場合は 5.7G、--si の場合は 6.1G だと思います。それで、ここで何が起きるのでしょうか?

% du --version
du (GNU coreutils) 8.20
...

% uname -a
Linux XXX 3.9-1-amd64 #1 SMP Debian 3.9.8-1 x86_64 GNU/Linux

答え1

スイッチを使用してテストを繰り返します--apparent-size

$ du -shc --apparent-size DIR ...

du のマニュアルページからの抜粋

--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

関連情報