CompTIA Linux+ (XK0-004) — Question 177
An administrator receives an alarm because the disk of one of the sewers is running out of space. Which of the following commands can be used to see the space that each partition is using?
Answer options
- A. df -h
- B. du -scg /
- C. fdisk -l
- D. fsck /
Correct answer: A
Explanation
The command 'df -h' displays the amount of disk space used and available on each mounted filesystem, making it the correct choice. The 'du -scg /' command shows the disk usage of files and directories but not the overall partition usage. 'fdisk -l' lists the partitions but not their usage, and 'fsck /' is used for checking and repairing filesystems, not for viewing space.