Courseiva
Workloads & Scheduling →hardMultiple Choice

CKA Workloads & Scheduling Practice Question

You have a StatefulSet with 5 pods, each requiring a unique stable network identity. The StatefulSet is scaled down from 5 to 3. Which pods will be terminated?

⚠ Common exam trap

Many candidates assume pods are terminated randomly or based on resource usage, but the CKA exam tests the specific deterministic behavior of StatefulSet scaling, which always removes pods with the highest ordinals first.

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

✓

Pods with the highest ordinals (4 and 3)

When a StatefulSet is scaled down, Kubernetes terminates pods in reverse order of their ordinal indices, starting from the highest. For a StatefulSet with 5 pods (ordinals 0-4) scaled to 3, pods with ordinals 4 and 3 are terminated first, ensuring that the remaining pods (0, 1, 2) maintain their stable network identities and storage.

Answer analysis

Option-by-option breakdown

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

  • ✗

    Random pods

    Why it's wrong here

    StatefulSet scale-down is deterministic, never random. When the desired replica count is reduced, the controller always removes pods in reverse ordinal order, starting from the highest ordinal (n-1) and proceeding downward. Random selection would violate the stable per-pod identity and matching PersistentVolumeClaims that StatefulSet guarantees, because those identities are bound to specific ordinals.

  • ✓

    Pods with the highest ordinals (4 and 3)

    Why this is correct

    Correct. The StatefulSet controller honors the ordinal ordering by deleting pods with the highest index numbers first. For a 5-pod StatefulSet (ordinals 0 through 4) scaling from 5 to 3 replicas, pods 4 and 3 are removed because they are the highest ordinals. This preserves the sequential identity of the remaining pods (0, 1, 2) and their associated storage, which is the core behavior of StatefulSet lifecycle management.

  • ✗

    Pods with the lowest ordinals (0 and 1)

    Why it's wrong here

    The lowest ordinals are the ones that survive a scale-down, not the ones removed. StatefulSet deliberately retains the smallest ordinals to maintain a contiguous range from 0 to (replicas-1) after the operation. Deleting pods 0 and 1 would create gaps (e.g., leaving ordinals 2, 3, 4) and break the stable identity model, so the controller would never choose them as the first to remove.

  • ✗

    Pods with the highest resource usage

    Why it's wrong here

    Resource usage is irrelevant to StatefulSet scale-down. The controller does not inspect CPU or memory utilization; it only checks the desired replica count against the current number of pods and deletes the highest ordinals to meet that count. Pod eviction based on resource pressure is handled by the kubelet or cluster autoscaler, not the StatefulSet controller's scaling logic.

About these practice questions

Courseiva writes every CKA question from scratch — 726 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 →

How Courseiva writes practice questions · Editorial policy

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.