Courseiva
Kubernetes Fundamentals →mediumMultiple Choice

KCNA Kubernetes Fundamentals Practice Question

A cluster administrator needs to run a node-level log collector that must read files from /var/log on every node in the cluster, including nodes added later. The collector does not need to run on control plane nodes. Which Kubernetes resource should be used?

⚠ Common exam trap

The trap here is assuming a Deployment with replica count matching node count provides per-node coverage, when only a DaemonSet guarantees one Pod per eligible node and handles new nodes automatically.

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

✓

DaemonSet

A DaemonSet is the correct resource because it schedules exactly one Pod on each node that matches its node selector or affinity rules, and it automatically adds Pods to new nodes as they join the cluster. This makes it ideal for node-level agents such as log collectors, monitoring daemons, and network plugins that must run everywhere.

Answer analysis

Option-by-option breakdown

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

  • ✓

    DaemonSet

    Why this is correct

    A DaemonSet ensures that a copy of a Pod runs on every eligible node, including nodes added after the DaemonSet is created. The collector can mount hostPath /var/log and apply a nodeSelector or affinity to exclude control plane nodes, satisfying the requirement without manual scheduling.

  • ✗

    Job with parallelism set to the node count

    Why it's wrong here

    A Job runs Pods to completion and is unsuitable for a continuously running log collector. Setting parallelism to the node count does not guarantee one Pod per node or coverage of future nodes, and completed Pods would not restart to collect ongoing logs. Jobs are for batch workloads.

  • ✗

    StatefulSet with podAntiAffinity

    Why it's wrong here

    A StatefulSet provides stable identities and ordered scaling, not per-node coverage. While podAntiAffinity can spread Pods, it cannot ensure exactly one Pod per node, and it does not automatically schedule onto newly added nodes. StatefulSets are intended for stateful applications, not node-level agents.

  • ✗

    Deployment with replicas equal to the number of nodes

    Why it's wrong here

    A Deployment manages a fixed replica count and does not guarantee one Pod per node. Replicas could be scheduled unevenly, multiple Pods could land on the same node, and new nodes would not automatically receive a collector Pod. It also lacks the per-node hostPath guarantee without extra scheduling constraints.

About these practice questions

One of 930 original KCNA 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 →

How Courseiva writes practice questions · Editorial policy

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 CNCF exam blueprint

This KCNA practice question is part of Courseiva's free CNCF 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 KCNA exam.