CKA Troubleshooting Practice Question
A pod is stuck in Pending state. 'kubectl describe pod' shows the event: '0/3 nodes are available: 3 node(s) didn't match pod anti-affinity rules'. What is the most likely cause?
⚠ Common exam trap
CNCF often tests the distinction between hard and soft scheduling constraints; the trap here is that candidates may confuse anti-affinity errors with resource insufficiency or taint issues, but the specific event message directly points to anti-affinity rules.
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 pod has a requiredDuringSchedulingIgnoredDuringExecution anti-affinity rule that is too restrictive
The event '0/3 nodes are available: 3 node(s) didn't match pod anti-affinity rules' directly indicates that the pod's scheduling is being blocked by anti-affinity constraints. Option B is correct because a `requiredDuringSchedulingIgnoredDuringExecution` anti-affinity rule is a hard constraint that must be satisfied at scheduling time; if no node meets the rule (e.g., the rule prevents co-location with other pods that are present on all nodes), the pod remains Pending.
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 nodes have insufficient resources
Why it's wrong here
Insufficient resources would surface in the scheduler's events as a FailedScheduling reason with messages like '0/3 nodes are available: 1 Insufficient cpu, 2 Insufficient memory.' That event explicitly names the missing resource, whereas anti-affinity failures report 'didn't match pod anti-affinity rules.' Also, resource constraints can often be resolved by moving other workloads, but the pod's own resource requests don't make the entire cluster ineligible unless every node lacks capacity.
- ✓
The pod has a requiredDuringSchedulingIgnoredDuringExecution anti-affinity rule that is too restrictive
Why this is correct
A requiredDuringSchedulingIgnoredDuringExecution anti-affinity rule is a hard constraint: the scheduler will only place the pod on a node that satisfies every term of the rule. If the rule's label selector and topologyKey match labels on pods running on every available node, no node passes the check. The resulting event is '0/3 nodes are available: 3 node(s) didn't match pod anti-affinity rules,' and the pod stays Pending until a node no longer runs a conflicting pod or the rule is updated. This is the only option where the pod's own scheduling constraints, not cluster conditions, make all nodes ineligible.
- ✗
The pod has a taint tolerance issue
Why it's wrong here
A taint/toleration mismatch would generate a completely different scheduler event: '3 node(s) had untolerated taint {key=value:NoSchedule}' (or NoExecute). That means the nodes are tainted and the pod lacks the corresponding toleration; the scheduler skips those nodes regardless of their available resources. This is unrelated to label-based pod relationships, and the fix is adding a toleration to the pod spec, not changing the cluster's node labels or topology.
- ✗
The nodes are all cordoned
Why it's wrong here
When nodes are cordoned, kubectl get nodes shows them as SchedulingDisabled, and the scheduler reports '0/3 nodes are available: 3 node(s) were unschedulable.' Cordon is an administrative action that sets the node's unschedulable flag, preventing any new pods from being placed there, but it does not consider pod affinity or toleration rules. The pod remains Pending because the node is intentionally marked unavailable, and it will only schedule after an admin runs kubectl uncordon.
Go deeper
Related to this question
About these practice questions
Courseiva writes every CKA question from scratch — 302 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or 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 CKA 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 CKA exam.