du(Disk Usage) - This command is use to check the size of file and directory.
Check the size of file
$ du filename/directory
Check multiple file and directory size
$ du file1 file2 dir1 dir2
Check all files and directory size in human-readable format
$ du -h filename
Check total size of any directory (use -s option)
$ du -sh /usr/local
Check all files and directory size of current directory
$ du -sh *
Check all files and directory size with -c option
$ du -ch *
4.0K service
532K v2.5.5.zip
4.0K web.json
4.0K webserver.yml
544K total
Check the sized based on modified time
du -sh --time filename
0 comments:
Post a Comment