Ch. 14 · Kubernetes

Kubernetes Deployments and Rolling Updates

Kubernetes Deployments and Rolling Updates. Learn the reasoning, a practical example, common mistakes and an interview exercise.

~2 min readbeginnerupdated Oct 3, 2026

Deployments manage desired replicas and revisioned rollout behavior. Availability depends on readiness, capacity and surge or unavailability settings.

Before you start

You should understand Pods, Deployments and Services. Read desired configuration separately from observed cluster state. Use a development cluster when trying changes, and inspect events and status rather than assuming that an accepted manifest means the workload is ready to serve traffic.

The practical goal is to reason through this situation: A new revision becomes ready before old instances are removed under a suitable rollout policy. Read the walkthrough first, then try the interview exercise before opening its answer. The important part is explaining the decision and its consequences, rather than remembering a definition alone.

Step-by-step walkthrough

Step 1: Read rollout policy

Check replica count, surge and permitted unavailability.

Step 2: Inspect readiness and scheduling

A new image is useful only if its Pods can start and serve.

Step 3: Diagnose the blocked boundary

Use events and status before triggering more replacements.

Worked scenario

A new revision becomes ready before old instances are removed under a suitable rollout policy.

A rollout creates new replicas that request more memory than any eligible node offers. Old replicas remain under the availability policy, but the rollout cannot progress. Restarting it repeats the same capacity issue. A different failure, such as a failing readiness probe, needs different evidence and remediation.

Common mistake

A rollout can stall when new Pods cannot schedule or pass readiness.

Verify the behavior

Inspect rollout status, Pod events and probes; verify available capacity for the chosen surge.

Interview exercise

Diagnose a stalled rollout.

Answer and reasoning

Inspect events, replica status, scheduling resources and probe failures before repeatedly restarting the Deployment.

Continue learning

Compare the scenario with the Kubernetes interview questions and test your understanding with the Kubernetes MCQs. For terminology and implementation details, consult the reference material.

More in Kubernetes

read ✓Kubernetes · mid

Kubernetes ConfigMap Update Behavior

Understand why ConfigMap changes reach volumes but not environment variables, and how to roll a Deployment deliberately.

~2 min readread →
read ✓Kubernetes · mid

Kubernetes emptyDir Volumes

Share scratch space between containers in a pod with emptyDir, choose the backing medium, and bound its size.

~2 min readread →
read ✓Kubernetes · hard

Kubernetes Gateway API for Ingress

Route traffic with GatewayClass, Gateway and HTTPRoute, and understand how the Gateway API improves on Ingress.

~2 min readread →
esc