CertLumen

Certified Kubernetes Application Developer (CKAD) · Section 2 · 20% of the exam

Understand Deployments and how to perform rolling updates

One of the objectives of the Certified Kubernetes Application Developer (CKAD) exam, in the section “Application Deployment”. Here is what it covers, the points to remember and a question to try.

What it covers

A Deployment manages ReplicaSets, and each change to the Pod template creates a new ReplicaSet and a revision. This lesson covers the rolling-update algorithm with maxSurge and maxUnavailable, kubectl rollout status, history, undo, pause and restart, scaling, and why a rollout can stall.

Points to remember

  • A Deployment manages ReplicaSets; a rollout is triggered only by a change to .spec.template. Scaling never creates a revision.
  • RollingUpdate is the default. maxSurge and maxUnavailable both default to 25%: surge rounds up, unavailable rounds down. They cannot both be 0.
  • Recreate stops all old Pods first and rejects rollingUpdate parameters.
  • minReadySeconds defaults to 0, progressDeadlineSeconds to 600 and revisionHistoryLimit to 10.
  • kubectl rollout status / history / undo [--to-revision=N] / pause / resume / restart are the core commands.

Try a question

A developer wants to change the image and the memory limit of Deployment web as one rollout, without Pods being replaced twice. Which sequence achieves this?

  1. APause the rollout, run set image and set resources, then resume
  2. BSet revisionHistoryLimit: 0 before editing
  3. CRun kubectl rollout restart after both changes
  4. DRun kubectl set image and kubectl set resources back to back with no pause
Show the answer

A. While a Deployment is paused, template edits are recorded but not rolled out. Resuming creates a single new ReplicaSet with all the changes.

Written for practice in the style of the exam: never a question from the real exam.

In the course

The lesson Deployments and Rolling Updates teaches this objective (about 45 minutes), and 13 practice questions test it. The course has lessons, exam-style questions, timed practice exams and an AI tutor for every objective, and a pass prediction that tells you when you're ready to book.

More in this section

← Previous objective · All 24 objectives · Next objective →