How to get the size of a directory in Linux

subject: Commands · date: 2017-12-08

To get size of file_path:

    $ du -sh file_path

The options -sh are:

  • -s: display only a total for each argument

  • -h: print sizes in human readable format (e.g., 1K 234M 2G)

read more

share this article