CV0-004 Troubleshooting Practice Question
A cloud administrator receives reports that a newly deployed application stack fails health checks and is repeatedly replaced by the orchestrator. Logs show the container starts, then exits after a few seconds with no error. The container image runs a process that daemonizes and returns control to the shell. Which of the following is the MOST likely cause?
⚠ Common exam trap
The trap here is focusing on the health check configuration when the container is exiting before health checks even matter, because the foreground process ends.
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 container's main process forks into the background, so the runtime sees the foreground process exit and stops the container.
Container lifecycle is bound to the foreground process. When the entrypoint backgrounds the application and returns, the runtime sees the main process complete and stops the container, so the orchestrator repeatedly recreates it. Running the server in the foreground or using a process supervisor keeps the container alive and allows health checks to succeed.
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 orchestrator's restart policy is set to Always, causing healthy containers to be restarted.
Why it's wrong here
A restart policy of Always restarts containers when they exit, but it does not cause a healthy container to exit in the first place. The observed exit is the root symptom, and the restarts are a consequence. Changing the policy would mask the loop without fixing the underlying process termination, and it would not explain the clean exit.
- ✗
The container image was built for the wrong CPU architecture and the kernel is killing the process.
Why it's wrong here
An architecture mismatch typically prevents execution entirely, producing an 'exec format error' at startup, and it would be consistent rather than allowing the process to run for a few seconds. The described behavior shows the process starting normally and then ending cleanly, which points to process lifecycle handling rather than binary incompatibility.
- ✓
The container's main process forks into the background, so the runtime sees the foreground process exit and stops the container.
Why this is correct
Container runtimes tie the container lifecycle to the foreground process. When an entrypoint script launches a daemon that backgrounds itself, the foreground process exits, the runtime treats the container as complete, and the orchestrator restarts it. The fix is to run the process in the foreground or use a supervisor that keeps a foreground process alive.
- ✗
The container's health check endpoint is returning 500 errors because the application is not fully initialized.
Why it's wrong here
A 500 from a health endpoint would appear in the application logs and would occur after the process is listening. Here the container exits within seconds with no error, which indicates the main process terminated rather than the application returning errors. A failing endpoint also would not cause the container runtime to consider the process finished.
Go deeper
Related to this question
About these practice questions
This CV0-004 question is part of Courseiva's 834-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. 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 CV0-004 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 CV0-004 exam.