du(1)
π NAME π
okay so bestie, welcome to du β she's from the General Commands Manual, and she's here to estimate file space usage. that's it. that's the whole job. she looks at your files and tells you how much room they're taking up. she's the friend who tells you your Downloads folder is 47 gigabytes. iconic behaviour, honestly. π«Ά
πΈ SYNOPSIS πΈ
like, the whole vibe in one block:
du [--help] [-a|--all] [-A|--apparent-size] [-B|--block-size]
[-b|--bytes] [-c|--total] [-d|--max-depth] [-h|--human-readable]
[--inodes] [-k ] [-l|--count-links] [-L|--dereference]
[-D|--dereference-args] [-P|--no-dereference] [-m ] [-0|--null]
[-S|--separate-dirs] [-s|--summarize] [--si] [-x|--one-file-system]
[-t|--threshold] [-v|--verbose] [--exclude] [-X|--exclude-from]
[--files0-from] [--time] [--time-style] [-V|--version] [FILE]
π¦ DESCRIPTION π¦
Estimate file space usage. that's the mission statement. she runs, she counts, she reports. main character energy, no cap. β¨
β¨ OPTIONS β¨
the way that every single one of these exists and mattersβ¦ let's go, one by one, no skipping, we don't do that here π
--helpβ print help information. the "hey what do i do" button.-a,--allβ write counts for all files, not just directories. every single one gets a moment in the spotlight. π-A,--apparent-sizeβ print apparent sizes instead of disk usage. and here's the tea: apparent size is usually smaller, but it can be larger β because of holes in ('sparse') files, internal fragmentation, indirect blocks, and the like. so she's measuring the vibe, not the actual footprint.-B,--block-size <SIZE>β scale sizes by SIZE before printing them. e.g.'-BM'prints sizes in units of1,048,576bytes. see SIZE format down below, bestie.-b,--bytesβ equivalent to'--apparent-size --block-size=1'. two-for-one, slay.-c,--totalβ produce a grand total. the grand finale. π-d,--max-depth <N>β print the total for a directory (or a file, if you're using--all) only if it's N or fewer levels below the command line argument. and listen:--max-depth=0is the same as--summarize. literally the same thing.-h,--human-readableβ print sizes in human readable format, like1K234M2G. so you don't have to do mental math at 2am. πΈ--inodesβ list inode usage information instead of block usage, like--block-size=1K. different stat, same energy.-kβ like--block-size=1K.-l,--count-linksβ count sizes many times if hard linked. yes, many times. she's thorough like that.-L,--dereferenceβ follow all symbolic links. no fear. π¦-D,--dereference-argsβ follow only the symlinks that are listed on the command line. selective dereferencing, we love boundaries.-P,--no-dereferenceβ don't follow any symbolic links. and heads up, this is the default β that's just how she comes out of the box.-mβ like--block-size=1M.-0,--nullβ end each output line with a0byte rather than a newline. for when newlines are the enemy.-S,--separate-dirsβ do not include the size of subdirectories. everyone gets their own little box.-s,--summarizeβ display only a total for each argument. short and sweet, she ate.--siβ like-h, but use powers of1000not1024. metric girlies rise. π-x,--one-file-systemβ skip directories on different file systems. stay in your lane, literally.-t,--threshold <SIZE>β exclude entries smaller than SIZE if it's positive, or entries greater than SIZE if it's negative. so like, a little sieve for your filesystem. π-v,--verboseβ verbose mode. and ngl, real talk: (option not present in GNU/Coreutils). just so you know.--exclude <PATTERN>β exclude files that match PATTERN. bye bestie π-X,--exclude-from <FILE>β exclude files that match any pattern in FILE. a whole list of exclusions, organised queen.--files0-from <FILE>β summarize device usage of the NUL-terminated file names specified in file F; if F is-, then read names from standard input. (that's literally what it says β file F.) π§--time[=<WORD>...]β show time of the last modification of any file in the directory, or any of its subdirectories. if WORD is given, show time as WORD instead of modification time:atime,access,use,ctime,status,birthorcreation.
Possible values:
atimectimecreation
--time-style <STYLE>β show times using style STYLE:full-iso,long-iso,iso,+FORMAT. and FORMAT is interpreted like'date'. π-V,--versionβ print version. the receipts.
π« EXTRA π«
okay this is the lore drop, pay attention π’
Display values are in units of the first available SIZE from --block-size, and the DU_BLOCK_SIZE, BLOCK_SIZE and BLOCKSIZE environment variables. Otherwise, units default to 1024 bytes β or 512 if POSIXLY_CORRECT is set. so yeah, those env vars are real and they're coming for your output format. π
SIZE is an integer and optional unit (example: 10M is 10*1024*1024). Units are K, M, G, T, P, E, Z, Y (powers of 1024) or KB, MB,... (powers of 1000). Units can be decimal, hexadecimal, octal, binary. so many flavours, all valid. β¨
PATTERN allows some advanced exclusions. for example, the following syntaxes are supported: ? will match only one character, * will match zero or more characters, {a,b} will match a or b. globby little things, obsessed. π
π VERSION π
v(uutils coreutils) 0.7.0
this isdufrom the uutils coreutils, version 0.7.0 β that's the source and the version, bestie, and the page signs off asdu (uutils coreutils) 0.7.0. runduresponsibly, check your disk space, hydrate, and remember: your home directory is not a storage unit. periodt. π π«Άπ
π¦ where this page comes from
- epel 10: rust-coreutils-devel 0.7.0-10.el10_3 Β· MIT
- epel 10: uutils-coreutils 0.7.0-10.el10_3 Β· (MIT OR Apache-2.0) AND Unicode-DFS-2016 AND Zlib AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR Apache-2.0 WITH LLVM-exception) AND (Apache-2.0 OR GPL-2.0-only) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-2-Clause AND (BSD-2-Clause OR Apache-2.0 OR MIT) AND BSD-3-Clause AND CC0-1.0 AND ISC AND MIT AND (MIT OR Zlib OR Apache-2.0) AND (MIT-0 OR Apache-2.0) AND Unicode-3.0 AND (Unlicense OR MIT)
- fedora 43: rust-coreutils-devel 0.7.0-12.fc43 Β· MIT
- fedora 43: uutils-coreutils 0.7.0-12.fc43 Β· (MIT OR Apache-2.0) AND Unicode-DFS-2016 AND Zlib AND (0BSD OR MIT OR Apache-2.0) AND Apache-2.0 AND (Apache-2.0 OR Apache-2.0 WITH LLVM-exception) AND (Apache-2.0 OR GPL-2.0-only) AND (Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT) AND BSD-2-Clause AND (BSD-2-Clause OR Apache-2.0 OR MIT) AND BSD-3-Clause AND CC0-1.0 AND ISC AND MIT AND (MIT OR Zlib OR Apache-2.0) AND (MIT-0 OR Apache-2.0) AND Unicode-3.0 AND (Unlicense OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms