Courseiva
Storage ManagementeasyMultiple ChoiceObjective-mapped

LFCS Storage Management Practice Question

An administrator wants to see the disk usage of the /var directory in a human-readable format. Which command should be used?

⚠ Common exam trap

Watch out — candidates often confuse `du` (directory usage) with `df` (filesystem usage), leading candidates to pick `df -h /var` because it shows space in human-readable format, but it does not measure the directory's own consumption.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

du -sh /var

The `du -sh /var` command is correct because `du` (disk usage) estimates file and directory space usage, and the `-s` flag summarizes the total for `/var` while `-h` provides human-readable output (e.g., KiB, MiB, GiB). This directly shows the disk space consumed by the `/var` directory and its contents.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • du -sh /var

    Why this is correct

    Correct command.

  • df -h /var

    Why it's wrong here

    Shows filesystem disk usage, not directory.

  • fdisk -l /var

    Why it's wrong here

    Fdisk works on block devices, not directories.

  • ls -lh /var

    Why it's wrong here

    Lists files, not directory total.

About these practice questions

Courseiva writes every LFCS question from scratch — 507 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This LFCS practice question is part of Courseiva's free Linux Foundation certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LFCS exam.