Courseiva
GNU and Unix CommandshardMultiple ChoiceObjective-mapped

LPIC-1 GNU and Unix Commands Practice Question

An administrator runs the command 'find / -name "*.conf" 2>/dev/null | head -n 10' and notices that the command returns very quickly. Which statement best describes what happened?

⚠ Common exam trap

Candidates often think `head` simply filters output after the command finishes, not realizing that pipe-induced SIGPIPE causes the upstream command to terminate early, which is why the command returns quickly.

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

It scans the entire filesystem but stops after sending the first 10 lines to head due to a broken pipe.

The `find` command starts scanning the entire filesystem from root (`/`), but its output is piped to `head -n 10`, which reads only the first 10 lines and then closes the pipe. When `head` closes the pipe, `find` receives a SIGPIPE signal (broken pipe) and terminates early, so the command returns very quickly without scanning the entire filesystem.

Answer analysis

Option-by-option breakdown

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

  • It scans the entire filesystem but stops after sending the first 10 lines to head due to a broken pipe.

    Why this is correct

    Find continues until it tries to write after head closes, then stops.

  • It lists 10 .conf files only from the current directory because the path is /.

    Why it's wrong here

    The path / means root, not current directory.

  • It lists all .conf files in the filesystem because head only affects output, not find.

    Why it's wrong here

    head terminates find via SIGPIPE.

  • It lists only the first 10 .conf files found in the filesystem.

    Why it's wrong here

    It lists the first 10 lines of output, but find may have found more; it stops early.

About these practice questions

Courseiva writes every LPIC-1 question from scratch — 527 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 LPIC-1 practice question is part of Courseiva's free LPI 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 LPIC-1 exam.