为什么Linux中的ls -l命令显示总计数?总共是什么? [重复]

问题描述 投票:-3回答:1

这个问题在这里已有答案:

ls -l显示文件的长格式以及权限。但总数没有。是什么?

linux unix command-line
1个回答
1
投票

我认为你的意思是以下

$ ls -l
total 1408600
...

如果是这样,答案可以在ls手册中找到。我通过在我的centos盒子上运行info coreutils 'ls invocation'来获取手册。

为了省你这么做......

For each directory that is listed, preface the files with a line
'total BLOCKS', where BLOCKS is the total disk allocation for all
files in that directory.  The block size currently defaults to 1024
bytes, but this can be overridden (*note Block size::).  The BLOCKS
computed counts each hard link separately; this is arguably a
deficiency.
© www.soinside.com 2019 - 2024. All rights reserved.