Free LPI 702-100 Actual Exam Questions - Question 1 Discussion
Not B, because df -h shows disk usage and includes network filesystems too. The mount command without options is better for just listing local mounted filesystems.
mount command without options actually lists all mounted filesystems, including local ones.
Actually, mount -a (D) doesn’t display anything; it just mounts all filesystems listed in /etc/fstab. That’s more about triggering mounts rather than showing what’s mounted right now. Also, cat /etc/fstab (A) just lists filesystems configured to mount at boot, not the ones currently active. So B (df -h) is better because it actually reports on mounted filesystems with their usage stats, which aligns well with what the question is asking. I’d rule out C and E because du -s is for disk usage on directories and rpcinfo is unrelated to mounting filesystems.
A/D? A shows what’s set to mount next time but not what’s mounted now; D mounts stuff but doesn’t display mounts. So neither helps show current filesystems like B does. B still feels right for current mounts.
I get why B is popular but I think D’s out too since mount -a only mounts, doesn’t list. A shows what could mount, not what’s mounted. So B for sure shows active mounts with space info. B
B imo, df -h gives a quick snapshot of mounted filesystems with space info, which fits the question better than A or D. A just shows configs, not active mounts.
D imo, mount -a is used to mount filesystems mentioned in fstab but doesn't display what's currently mounted. So it's not for showing current mounts. That leaves df -h as the clear choice since it lists all mounted filesystems along with their usage stats. The others either show configs or something unrelated.
B. df -h shows mounted filesystems with usage; A is just a config file listing, not actual mounts. C and D don’t list current mounts properly, E is unrelated.