XK0-006 Services and User Management Practice Question
A Linux administrator needs to ensure that a new service, myapp.service, starts automatically at boot and is currently running. The administrator runs 'systemctl enable --now myapp.service' and receives no errors, but after a reboot the service is not running. Which of the following is the most likely cause?
⚠ Common exam trap
The trap here is assuming that enable --now guarantees boot persistence even when the unit lacks an [Install] section, which silently makes enable ineffective for boot.
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
✓
The service unit file is missing the [Install] section with WantedBy=multi-user.target.
The [Install] section defines how a unit integrates with systemd's boot targets. WantedBy=multi-user.target is what allows enable to create the symlink that pulls the service into the boot transaction. Without it, enable --now starts the unit but does not configure it for automatic startup, so after reboot the service remains inactive.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
The systemctl daemon-reload command was not run after creating the unit file.
Why it's wrong here
daemon-reload is needed when unit files are added or changed while systemd is running, but the scenario says enable --now succeeded without errors. If daemon-reload were required, systemctl would typically report that the unit file was not found or that it needs to be reloaded, causing a visible failure.
- ✗
The service is masked by another unit with the same name in /etc/systemd/system.
Why it's wrong here
A masked unit would prevent the service from starting at all, and systemctl enable --now would fail with an error about the unit being masked. Since the command completed without errors and the service ran initially, masking is not the cause of the boot failure.
- ✗
The service was started with systemctl start instead of systemctl enable --now.
Why it's wrong here
The scenario explicitly states that systemctl enable --now was used, which both enables and starts the service. Replacing it with systemctl start would only start the service immediately and would not enable it for boot, making the situation worse, not better.
- ✓
The service unit file is missing the [Install] section with WantedBy=multi-user.target.
Why this is correct
Without an [Install] section specifying WantedBy, systemctl enable --now creates no symlink in the target's .wants directory. The service starts now but will not start at boot because systemd has no dependency link to multi-user.target, so the enable action is effectively a no-op for boot.
Go deeper
Related to this question
Learn chapter
System Services and Startup
Key term
Linux
Linux is an open-source operating system that manages computer hardware and software, widely used in servers, desktops, and embedded systems.
Key term
User
A user is any person, system, or device that interacts with an IT service, resource, or identity system, typically authenticated through credentials and authorized to perform specific actions.
About these practice questions
One of 781 original XK0-006 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official CompTIA exam blueprint
This XK0-006 practice question is part of Courseiva's free CompTIA 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 XK0-006 exam.