nerdexam
Linux_FoundationLinux_Foundation

KCNA · Question #65

KCNA Question #65: Real Exam Question with Answer & Explanation

The correct answer is D: Labels. The nodeSelector field in a PodSpec uses node labels to constrain which nodes a Pod is eligible to be scheduled on.

Submitted by khalil_dz· May 4, 2026Kubernetes Fundamentals

Question

What does the "nodeSelector" within a PodSpec use to place Pods on the target nodes?

Options

  • AAnnotations
  • BIP Addresses
  • CHostnames
  • DLabels

Explanation

The nodeSelector field in a PodSpec uses node labels to constrain which nodes a Pod is eligible to be scheduled on.

Common mistakes.

  • A. Annotations are used for non-identifying metadata and do not influence Pod scheduling decisions like nodeSelector does.
  • B. While nodes have IP addresses, nodeSelector does not directly use IP addresses for scheduling; it relies on labels for declarative node selection.
  • C. Hostnames are identifiers for nodes, but nodeSelector operates on arbitrary key-value labels, offering more flexible and generic selection than just hostnames.

Concept tested. Kubernetes Pod scheduling with nodeSelector

Reference. https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector

Topics

#Kubernetes Scheduling#nodeSelector#Node Labels#Pod Placement

Community Discussion

No community discussion yet for this question.

Full KCNA PracticeBrowse All KCNA Questions