Difficulty: Easy
Correct Answer: du
Explanation:
Introduction / Context:
Administrators frequently need to identify which directories or files consume space. Unix provides standard utilities to summarize disk usage efficiently, assisting in cleanup, quota checks, and capacity planning.
Given Data / Assumptions:
Concept / Approach:
The du command (disk usage) reports the number of blocks or human-readable sizes used by files and directories. Options like -s (summary) and -h (human-readable) are common combinations. Other listed commands are from different ecosystems or serve different purposes.
Step-by-Step Solution:
Verification / Alternative check:
Running du -sh /var/ quickly reveals which subdirectories occupy the most space. This is the canonical approach for Unix-like systems.
Why Other Options Are Wrong:
Common Pitfalls:
Confusing 'du' with 'df'. df reports filesystem-level free/used space; du drills down into directories and files. For complete analysis, both are useful together.
Final Answer:
du
Discussion & Comments