Forum Moderators: bakedjake
's' means a summary - just show the sizes of files/directories explicitly listed on the command line. Otherwise, 'du' will list size for every file in a named directory. 'h' is for "human-readable" output - it will pick a reasonable size unit to display in, and mark it as mb, kb, gb, etc.
very useful way to find where your biggest disk usage in a dir is:
du -sm /path/to/dir/* ¦ sort -n
list disk usage of each sub-dir or file in the top level of /path/to/dir, sorted by size in megabytes.
dingman@andrew:~$ du -sm * ¦ sort -n
.
.
.
1 wedding_photos
3 public_html
3 viavoice
3 visor-backup
5 MyPilot
6 software
7 cps_docs
7 cs_politics
10 gnucash
16 MyVisor
25 employment
28 War_of_the_Worlds.mp3
37 financial_records
38 Mail
82 temp
84 classwork
180 dingman1-home
251 evolution
806 kernel
1028 mp3
looks like 'cd kernel; make clean' might be a good idea if I'm short on disk space :) Likewise, I really oughta get that blasted cable to connect my CD-ROM to my sound card so I don't have to rip all my disks to play them in my office anymore.
That makes Johnny a dull boy.