hardMultiple SelectObjective-mapped
XK0-006 Practice Question: Which THREE conditions must be met for a Linux…
Which THREE conditions must be met for a Linux container to run with user namespaces enabled? (Choose three.)
⚠ Common exam trap
CompTIA often tests the misconception that a container must have UID 0 in its image or be started with root privileges to use user namespaces, when in fact user namespaces map an unprivileged host user to UID 0 inside the container.
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 runtime must be configured to use user namespaces.
User namespaces must be explicitly enabled in the container runtime configuration (e.g., `--userns=host` or `userns-remap` in Docker/Podman) to isolate the container's UID/GID mappings from the host. Without this configuration, the container will run in the default host namespace, negating the security benefits of user namespaces.
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 container image must have a user with UID 0.
Why it's wrong here
User namespaces remap UIDs, so the image can have UID 0 mapped to an unprivileged host UID.
- ✓
The container runtime must be configured to use user namespaces.
Why this is correct
Docker requires --userns-remap to enable user namespaces.
- ✓
The kernel must support user namespaces (CONFIG_USER_NS=y).
Why this is correct
Kernel support for user namespaces is required.
- ✗
The container must be started with root privileges.
Why it's wrong here
User namespaces allow containers to run without root.
- ✓
The sysctl kernel.unprivileged_userns_clone must be set to 1.
Why this is correct
This enables unprivileged user namespace creation.
Go deeper
Related to this question
Learn chapter
Linux Fundamentals and History
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
This XK0-006 question is part of Courseiva's 979-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 by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
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.