XK0-005 · Question #235
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?
The correct answer is A. df -h. To determine the disk space usage for each mounted partition on a Linux system, the df command provides a clear overview.
Question
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?
Options
- Adf -h
- Bdu -scg /
- Cfdisk -l
- Dfsck /
How the community answered
(31 responses)- A94% (29)
- C3% (1)
- D3% (1)
Why each option
To determine the disk space usage for each mounted partition on a Linux system, the `df` command provides a clear overview.
The `df -h` command displays disk space usage for all mounted filesystems (partitions) in a human-readable format, showing total size, used space, available space, and percentage used for each partition, which directly answers the administrator's need.
`du -scg /` calculates the disk usage of files and directories *within* the specified path (`/` in this case) and provides a total, but it doesn't show the overall usage statistics for each mounted partition.
`fdisk -l` lists the partition table and sizes of disk partitions but does not report their current usage or free space, which is dynamic filesystem information.
`fsck /` is a utility used to check and repair Linux filesystems for errors, not to report on their current disk space utilization.
Concept tested: Linux disk space usage reporting
Source: https://www.man7.org/linux/man-pages/man1/df.1.html
Topics
Community Discussion
No community discussion yet for this question.