Timeline for How do I get the size of a directory on the command line?
Current License: CC BY-SA 4.0
16 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jun 16, 2021 at 21:41 | comment | added | Max Yaskov | Option --si like -h, but use powers of 1000 not 1024. | |
| May 8, 2021 at 20:15 | comment | added | Sasgorilla | I'm looking right now at a folder I just copied from an external drive. It contains four files (no hardlinks). du -ba $folder reports that each of these files is identical in size across the copied folders, but the total at the folder level does not match. du -bs, du -h, etc., same answer. (One folder size is six bytes more than the sum of the files; the other is ~10% larger.) I've seen this issue before comparing a folder on an external drive. Is there any unix command that will reliably report two folders containing identical files as being the same "size"? | |
| Mar 20, 2021 at 10:51 | comment | added | Rmano | @CharlieParker no that I know of... | |
| Mar 19, 2021 at 22:02 | comment | added | Charlie Parker | @Rmano is there a single command that works with hardlinks? | |
| Apr 16, 2019 at 6:02 | comment | added | Alex Glukhovtsev | It works very nice with find e.g. to count the amount of space in specific subdirectories in current path: $ find . -type d -name "node_modules" -prune -exec du -sh {} \; | |
| Nov 25, 2018 at 5:06 | review | Suggested edits | |||
| Nov 25, 2018 at 5:43 | |||||
| S May 20, 2018 at 3:03 | history | suggested | Kamil Kiełczewski | CC BY-SA 4.0 | explanation of name 'du' |
| May 19, 2018 at 14:05 | review | Suggested edits | |||
| S May 20, 2018 at 3:03 | |||||
| S Nov 29, 2016 at 16:09 | history | suggested | tremendows | CC BY-SA 3.0 | more user-friendly position of the information |
| Nov 29, 2016 at 15:59 | review | Suggested edits | |||
| S Nov 29, 2016 at 16:09 | |||||
| Feb 20, 2015 at 16:03 | history | edited | terdon♦ | CC BY-SA 3.0 | Added some more detail |
| Feb 20, 2015 at 10:31 | comment | added | Rmano | ...unless you have hardlinks ;-) stackoverflow.com/questions/19951883/… | |
| Feb 19, 2015 at 18:23 | vote | accept | Abdul Al Hazred | ||
| Feb 19, 2015 at 17:44 | review | Low quality posts | |||
| Feb 19, 2015 at 17:58 | |||||
| Feb 19, 2015 at 17:27 | review | First posts | |||
| Feb 19, 2015 at 17:29 | |||||
| Feb 19, 2015 at 17:23 | history | answered | sam | CC BY-SA 3.0 |