Amiga Unix — 68040 · 68060

Manual pages › General commands (1)

du(1)

estimate file space usage

Package: coreutil, added for amigaux.

Also by this name: du(1M), System administration commands · du(1B), BSD versions of commands

du - estimate file space usage

du [OPTION]... [FILE]...

Summarize disk usage of each FILE, recursively for directories.

Mandatory arguments to long options are mandatory for short options too.

write counts for all files, not just directories
print apparent sizes, rather than disk usage; although the apparent size is usually smaller, it may be larger due to holes in (`sparse') files, internal fragmentation, indirect blocks, and the like

-B, --block-size=SIZE use SIZE-byte blocks

equivalent to `--apparent-size --block-size=1'
produce a grand total
dereference FILEs that are symbolic links
like --si, but also evokes a warning; will soon change to be equivalent to --dereference-args (-D)
print sizes in human readable format (e.g., 1K 234M 2G)
like -h, but use powers of 1000 not 1024
like --block-size=1K
count sizes many times if hard linked
dereference all symbolic links
don't follow any symbolic links (this is the default)
-0, --null
end each output line with 0 byte rather than newline
do not include size of subdirectories
display only a total for each argument
skip directories on different filesystems
Exclude files that match any pattern in FILE.

--exclude=PATTERN Exclude files that match PATTERN.

print the total for a directory (or file, with --all) only if it is N or fewer levels below the command line argument; --max-depth=0 is the same as --summarize
display this help and exit
output version information and exit

SIZE may be (or may be an integer optionally followed by) one of following: kB 1000, K 1024, MB 1000*1000, M 1024*1024, and so on for G, T, P, E, Z, Y.

PATTERN is a shell pattern (not a regular expression). The pattern ? matches any one character, whereas * matches any string (composed of zero, one or multiple characters). For example, *.o will match any files whose names end in .o. Therefore, the command

du --exclude='*.o'

will skip all files and subdirectories ending in .o (including the file .o itself).

Written by Torbjorn Granlund, David MacKenzie, Paul Eggert, and Jim Meyering.

Report bugs to <bug-coreutils@gnu.org>.

Copyright © 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

The full documentation for du is maintained as a Texinfo manual. If the info and du programs are properly installed at your site, the command

info coreutils du

should give you access to the complete manual.

March 2004 du (coreutils) 5.2.1