Courseiva
Service ConfigurationeasyMultiple ChoiceObjective-mapped

LFCS Service Configuration Practice Question

To check the details of a failed systemd service unit, including the last log entries, which command is most appropriate?

⚠ Common exam trap

Watch out — candidates often confuse `systemctl is-failed` (which only checks the failure state) with `systemctl status` (which provides both the state and the logs), leading them to choose a command that gives insufficient diagnostic information for the question's requirement of 'including the last log entries'.

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

systemctl status service

`systemctl status service` is the most appropriate command because it displays the current state of the service unit, including whether it is active, failed, or inactive, along with the last several log entries from the journal for that unit. This provides both the failure status and the contextual log output needed to diagnose why the service failed, all in a single command.

Answer analysis

Option-by-option breakdown

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

  • systemctl status service

    Why this is correct

    Shows current state and last log lines.

  • systemctl list-units --failed

    Why it's wrong here

    Lists failed units but does not show logs.

  • systemctl is-failed service

    Why it's wrong here

    Only returns exit status, no logs.

  • systemctl show service

    Why it's wrong here

    Shows properties, not recent logs.

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.