man-pages/man1/du.1.html
2021-03-31 01:06:50 +01:00

199 lines
6.3 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of DU</TITLE>
</HEAD><BODY>
<H1>DU</H1>
Section: User Commands (1)<BR>Updated: September 2019<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
du - estimate file space usage
<A NAME="lbAC">&nbsp;</A>
<H2>SYNOPSIS</H2>
<B>du</B>
[<I>,OPTION/</I>]... [<I>,FILE/</I>]...
<BR>
<B>du</B>
[<I>,OPTION/</I>]... <I>,--files0-from=F/</I>
<A NAME="lbAD">&nbsp;</A>
<H2>DESCRIPTION</H2>
<P>
Summarize disk usage of the set of FILEs, recursively for directories.
<P>
Mandatory arguments to long options are mandatory for short options too.
<DL COMPACT>
<DT id="1"><B>-0</B>, <B>--null</B><DD>
end each output line with NUL, not newline
<DT id="2"><B>-a</B>, <B>--all</B><DD>
write counts for all files, not just directories
<DT id="3"><B>--apparent-size</B><DD>
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
<DT id="4"><B>-B</B>, <B>--block-size</B>=<I>,SIZE/</I><DD>
scale sizes by SIZE before printing them; e.g.,
'-BM' prints sizes in units of 1,048,576 bytes;
see SIZE format below
<DT id="5"><B>-b</B>, <B>--bytes</B><DD>
equivalent to '--apparent-size <B>--block-size</B>=<I>,1/</I>'
<DT id="6"><B>-c</B>, <B>--total</B><DD>
produce a grand total
<DT id="7"><B>-D</B>, <B>--dereference-args</B><DD>
dereference only symlinks that are listed on the
command line
<DT id="8"><B>-d</B>, <B>--max-depth</B>=<I>,N/</I><DD>
print the total for a directory (or file, with <B>--all</B>)
only if it is N or fewer levels below the command
line argument; <B>--max-depth</B>=<I>,0/</I> is the same as
<B>--summarize</B>
<DT id="9"><B>--files0-from</B>=<I>,F/</I><DD>
summarize disk usage of the
NUL-terminated file names specified in file F;
if F is -, then read names from standard input
<DT id="10"><B>-H</B><DD>
equivalent to <B>--dereference-args</B> (<B>-D</B>)
<DT id="11"><B>-h</B>, <B>--human-readable</B><DD>
print sizes in human readable format (e.g., 1K 234M 2G)
<DT id="12"><B>--inodes</B><DD>
list inode usage information instead of block usage
<DT id="13"><B>-k</B><DD>
like <B>--block-size</B>=<I>,1K/</I>
<DT id="14"><B>-L</B>, <B>--dereference</B><DD>
dereference all symbolic links
<DT id="15"><B>-l</B>, <B>--count-links</B><DD>
count sizes many times if hard linked
<DT id="16"><B>-m</B><DD>
like <B>--block-size</B>=<I>,1M/</I>
<DT id="17"><B>-P</B>, <B>--no-dereference</B><DD>
don't follow any symbolic links (this is the default)
<DT id="18"><B>-S</B>, <B>--separate-dirs</B><DD>
for directories do not include size of subdirectories
<DT id="19"><B>--si</B><DD>
like <B>-h</B>, but use powers of 1000 not 1024
<DT id="20"><B>-s</B>, <B>--summarize</B><DD>
display only a total for each argument
<DT id="21"><B>-t</B>, <B>--threshold</B>=<I>,SIZE/</I><DD>
exclude entries smaller than SIZE if positive,
or entries greater than SIZE if negative
<DT id="22"><B>--time</B><DD>
show time of the last modification of any file in the
directory, or any of its subdirectories
<DT id="23"><B>--time</B>=<I>,WORD/</I><DD>
show time as WORD instead of modification time:
atime, access, use, ctime or status
<DT id="24"><B>--time-style</B>=<I>,STYLE/</I><DD>
show times using STYLE, which can be:
full-iso, long-iso, iso, or +FORMAT;
FORMAT is interpreted like in 'date'
<DT id="25"><B>-X</B>, <B>--exclude-from</B>=<I>,FILE/</I><DD>
exclude files that match any pattern in FILE
<DT id="26"><B>--exclude</B>=<I>,PATTERN/</I><DD>
exclude files that match PATTERN
<DT id="27"><B>-x</B>, <B>--one-file-system</B><DD>
skip directories on different file systems
<DT id="28"><B>--help</B><DD>
display this help and exit
<DT id="29"><B>--version</B><DD>
output version information and exit
</DL>
<P>
Display values are in units of the first available SIZE from <B>--block-size</B>,
and the DU_BLOCK_SIZE, BLOCK_SIZE and BLOCKSIZE environment variables.
Otherwise, units default to 1024 bytes (or 512 if POSIXLY_CORRECT is set).
<P>
The SIZE argument is an integer and optional unit (example: 10K is 10*1024).
Units are K,M,G,T,P,E,Z,Y (powers of 1024) or KB,MB,... (powers of 1000).
<A NAME="lbAE">&nbsp;</A>
<H2>PATTERNS</H2>
PATTERN is a shell pattern (not a regular expression). The pattern
<B>?</B>
matches any one character, whereas
<B>*</B>
matches any string (composed of zero, one or multiple characters). For
example,
<B>*.o</B>
will match any files whose names end in
<B>.o</B>.
Therefore, the command
<DL COMPACT>
<DT id="30"><DD>
<B>du --exclude='*.o'</B>
</DL>
<P>
will skip all files and subdirectories ending in
<B>.o</B>
(including the file
<B>.o</B>
itself).
<A NAME="lbAF">&nbsp;</A>
<H2>AUTHOR</H2>
Written by Torbjorn Granlund, David MacKenzie, Paul Eggert,
and Jim Meyering.
<A NAME="lbAG">&nbsp;</A>
<H2>REPORTING BUGS</H2>
GNU coreutils online help: &lt;<A HREF="https://www.gnu.org/software/coreutils/">https://www.gnu.org/software/coreutils/</A>&gt;
<BR>
Report du translation bugs to &lt;<A HREF="https://translationproject.org/team/">https://translationproject.org/team/</A>&gt;
<A NAME="lbAH">&nbsp;</A>
<H2>COPYRIGHT</H2>
Copyright &#169; 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later &lt;<A HREF="https://gnu.org/licenses/gpl.html">https://gnu.org/licenses/gpl.html</A>&gt;.
<BR>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
<A NAME="lbAI">&nbsp;</A>
<H2>SEE ALSO</H2>
Full documentation at: &lt;<A HREF="https://www.gnu.org/software/coreutils/du">https://www.gnu.org/software/coreutils/du</A>&gt;
<BR>
or available locally via: info '(coreutils) du invocation'
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="31"><A HREF="#lbAB">NAME</A><DD>
<DT id="32"><A HREF="#lbAC">SYNOPSIS</A><DD>
<DT id="33"><A HREF="#lbAD">DESCRIPTION</A><DD>
<DT id="34"><A HREF="#lbAE">PATTERNS</A><DD>
<DT id="35"><A HREF="#lbAF">AUTHOR</A><DD>
<DT id="36"><A HREF="#lbAG">REPORTING BUGS</A><DD>
<DT id="37"><A HREF="#lbAH">COPYRIGHT</A><DD>
<DT id="38"><A HREF="#lbAI">SEE ALSO</A><DD>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 00:05:11 GMT, March 31, 2021
</BODY>
</HTML>