LFCS Service Configuration Practice Question
A service named webserver.service is failing to start. The administrator wants to see the most recent error messages related to this service. Which command provides this information?
⚠ Common exam trap
Many exam-takers confuse `systemctl status` (which shows a brief log snippet) with `journalctl -u` (which provides the full, searchable journal), assuming the status command gives complete error history when it only shows a truncated view.
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
✓
journalctl -u webserver.service
The `journalctl -u webserver.service` command queries the systemd journal for all log entries associated with the specified unit, showing the most recent error messages in reverse chronological order. This is the standard way to view detailed, time-stamped error logs for a failing service, as `journalctl` provides access to the binary journal that captures stdout, stderr, and syslog messages from the service.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
journalctl -u webserver.service
Why this is correct
Shows logs for the unit, including recent errors.
- ✗
systemctl status webserver.service --full
Why it's wrong here
Shows status but may not display full logs.
- ✗
systemctl list-units --type=service | grep webserver
Why it's wrong here
Lists units but does not show error messages.
- ✗
systemctl is-active webserver.service
Why it's wrong here
Only returns active/inactive state.
Go deeper
Related to this question
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 →
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.