Festplatte & SpeicherCLI Manual
$du
Estimate file and directory space usage.
BefehlssyntaxPOSIX Standard
du [OPTIONS] [FILE...]Live im interaktiven Terminal ausprobieren
Client-seitige Simulation ohne Installation mit sofortigem Feedback.
bash — terminal
AST Sandbox (Free)
Überblick & Funktionsweise
`du` (Disk Usage) measures the space occupied by individual files and folders on disk. Unlike `df` which inspects entire partitions, `du` recursively scans directories to identify which folders or log files are consuming disk space.
Wichtige Optionen und Flags
| Flag / Option | Description |
|---|---|
| -s, --summarize | Display only a total sum for each specified directory argument. |
| -h, --human-readable | Print sizes in human readable format (e.g., 24K, 500M, 4G). |
| -d, --max-depth=N | Print total for a directory only if it is N or fewer levels below. |
Praktische Anwendungsbeispiele
#1Check folder size summary
du -sh /var/logOutputs the total human-readable size of the /var/log directory.
Verwandte Linux-Befehle
$findDateioperationen
Durchsuchen Sie Verzeichnishierarchien nach Dateien basierend auf Name, Typ, Größe oder Änderungsdatum.
$lsNavigation
Verzeichnisinhalte auflisten mit Dateigrößen, Berechtigungen und Zeitstempeln.
$dfFestplatte & Speicher
Report file system disk space usage across mounted storage partitions.
$freeFestplatte & Speicher
Display total amount of free and used physical memory and swap.