Difficulty: Medium
Correct Answer: -s
Explanation:
Introduction / Context:
The du (disk usage) command reports filesystem usage in blocks or human-readable units. Choosing the correct option lets administrators quickly summarize consumption by a file or directory, which is crucial for quota checks and cleanup tasks on multi-user systems.
Given Data / Assumptions:
Concept / Approach:
du -s prints a summary for each argument—effectively the total blocks used by that file or directory, instead of listing every subentry. Other switches: -c adds a grand total line, -i (on some platforms) reports inode usage, and -d limits depth (GNU extension), but none replace the summary role of -s.
Step-by-Step Solution:
Verification / Alternative check:
Example: du -s /var/log outputs a single number and path, representing total blocks used by /var/log, confirming the summary behavior.
Why Other Options Are Wrong:
Common Pitfalls:
Final Answer:
-s.
Discussion & Comments