How can I make the "du" command without listing all directories, for example, in silent mode?

I am trying to get the size of a directory on Linux, but it has many subdirectories and seems to go into all of these files and directories forever before giving me an answer on what size. I searched for reference and manual recording and online, but I can not find anything. Does it really have to display every directory when scanning it? Is there a way to speed up this process? Usually with other commands, you can simply use the -q tick mode switch.

+4
source share
1 answer

Use the -s(summarize) option :

du -sh folder

(-h , , , , ..)

+6

Source: https://habr.com/ru/post/1568143/


All Articles