Field contextLesson 2 of 4
  1. SLOs and error budgets, not reconciled
  2. Incident response and postmortems, not reconciled
    1. Severity levels
    2. Roles
    3. Mitigate first
    4. On-call health
    5. Runbooks and playbooks
    6. Blameless postmortems
  3. Multi-cluster and platform engineering, not reconciled
  4. Cost and capacity, not reconciled

Incident response and postmortems

An incident goes better with named roles, a severity that sets the pace, and mitigation before diagnosis. Afterwards a blameless postmortem turns the outage into owned fixes.

  • 15 min
  • 4 objectives
  • 6 scenes

Shows the lesson one block at a time. Arrow keys step, number keys jump to a scene, and Escape returns to the page where you were.

Incidents are rarely lost for lack of technical skill. They are lost when five people change the system at once, when nobody tells customers what is happening, or when the team spends an hour finding the root cause while users wait. Incident response is the set of habits that prevents that, and the postmortem is how the next incident gets shorter.

Reconcile, in 6 scenes

Severity levels

A severityA level, usually SEV1 to SEV3, chosen by user impact, that sets who is paged, how often updates go out and how urgent the work is. is declared early and changed freely as facts arrive. Over-declaring costs a few interrupted people; under-declaring costs the response.

LevelTypical impactResponse
SEV1A core function down or data at risk for many usersPage on-call and an incident commander immediately; status updates every 30 minutes; all other work stops
SEV2Degraded or partial outage, or a SEV1 contained by a workaroundPage on-call; updates every hour; fix within the day
SEV3Minor or internal impact, no SLO at riskTicket; handled in working hours

The exact thresholds belong to each organization. What matters is that they are written down in terms of user impact, so the person on call does not have to decide alone how bad “bad” is.

Roles

Google’s incident management, modelled on the Incident Command System, separates four jobs:

  • The incident commanderThe person who holds the overall state of an incident, assigns roles and makes decisions. They hold every role they have not delegated. keeps the big picture and decides. In a large incident they do not type commands.
  • The operations lead and their team are the only people changing the system, so two fixes never collide.
  • The communications lead posts regular updates to stakeholders and customers, on the cadence the severity set.
  • The planning role supports operations with longer-term work: filing follow-up bugs, arranging handoffs and tracking every temporary change that must be reverted.

The commander also keeps a living incident document: what is known, who holds which role, and a timestamped log of actions. Many teams give the typing to a scribe, and that log becomes the postmortem’s timeline. In a small incident one person holds several roles. The handoff is explicit: “you have command” is said out loud and acknowledged, and so is the end of the incident.

Mitigate first

The first goal is to stop the user impact, not to understand it. Roll back the change that preceded the symptoms, scale out, fail over to another region, or turn off a feature flag, then investigate with the pressure off. A Deployment keeps its previous ReplicaSets, so a bad rollout is one command away from being undone:

Rolling back a bad checkout release
kubectl -n shop set image deployment/checkout checkout=ghcr.io/kx-labs/web:1.2-broken
deployment.apps/checkout image updated
kubectl -n shop get pods
NAME                        READY   STATUS             RESTARTS      AGE
checkout-78bbb85fbb-4zlwf   0/1     CrashLoopBackOff   2 (18s ago)   35s
checkout-78bbb85fbb-w7tll   0/1     CrashLoopBackOff   3 (1s ago)    40s
checkout-dfc847bf9-2cv2c    1/1     Running            0             60s
checkout-dfc847bf9-tfgs5    1/1     Running            0             60s
kubectl -n shop rollout history deployment/checkout
deployment.apps/checkout 
REVISION  CHANGE-CAUSE
1         <none>
2         <none>
kubectl -n shop rollout undo deployment/checkout
deployment.apps/checkout rolled back
kubectl -n shop rollout status deployment/checkout
Waiting for deployment "checkout" rollout to finish: 1 old replicas are pending termination...
deployment "checkout" successfully rolled out
kubectl -n shop get deployment checkout -o jsonpath='{.spec.template.spec.containers[0].image}'
ghcr.io/kx-labs/web:1.1

The rolling update stalled part-way. With no readiness probe, each new pod counted as ready for the second it ran before crashing, long enough for the Deployment to retire one old replica, so two old pods were left serving all the traffic. A readiness probe that the broken build fails would have held all three. Rollback removed the crashing pods and returned the Deployment to a clean state.

Capture evidence while mitigating, because Kubernetes does not keep it. Events are deleted after one hour by default (the API server’s --event-ttl), the logs of a replaced container are gone once its pod is deleted, and kubectl logs --previous reaches back only one restart. Save kubectl get events, kubectl describe and logs into the incident channel early.

On-call health

People who are paged constantly stop reading pages. Google’s SRE book caps on-call at 25% of an engineer’s time, which takes at least eight people for a single-site rotation with a primary and a secondary, and sets two incidents per 12-hour shift as the most anyone can handle well, given about six hours of response and follow-up each. Healthy on-call has a written handoff at each shift change, a review of every page (was it actionable, was it urgent), and the authority to delete alerts that are neither.

Paging and incident tooling sits on top: PagerDuty, incident.io, Grafana IRM or Jira Service Management. Atlassian ended Opsgenie sales on June 4, 2025 and ends its support on April 5, 2027, moving its users to Jira Service Management or Compass.

Runbooks and playbooks

A runbook is written for someone woken at 3 a.m. who has never seen the alert. Each step gives the exact command, what output means “fine”, and what to do otherwise. Write the expected output from a real run, not from memory:

A restart step, and the check that it finished
kubectl -n shop rollout restart deployment/checkout
deployment.apps/checkout restarted
kubectl -n shop rollout status deployment/checkout
Waiting for deployment "checkout" rollout to finish: 1 out of 3 new replicas have been updated...
Waiting for deployment "checkout" rollout to finish: 2 out of 3 new replicas have been updated...
Waiting for deployment "checkout" rollout to finish: 1 old replicas are pending termination...
deployment "checkout" successfully rolled out
kubectl -n shop get deployment checkout
NAME       READY   UP-TO-DATE   AVAILABLE   AGE
checkout   3/3     3            3           24s

rollout restart returns at once: it only patches an annotation on the pod template. rollout status is the step that waits, and it exits non-zero if the Deployment passes its progress deadline, which makes it safe to script. A good runbook entry also says when to stop following it and escalate.

Blameless postmortems

Google’s SRE book lists the usual triggers for a postmortem: user-visible downtime or degradation beyond a threshold, any data loss, an on-call intervention such as a rollback or traffic reroute, a resolution time above a threshold, and a monitoring failure that left humans to discover the problem. A postmortem has:

  • Impact: who was affected, how much, for how long, and how much error budget it spent.
  • Timeline: timestamps from the trigger through detection, mitigation and resolution, built from the incident document, chat logs and deploy history.
  • Contributing factors: the conditions that together allowed the outage. There is rarely a single root cause.
  • What went well, what went poorly, where we got lucky: luck is a factor that will not be there next time.
  • Action items: each with one owner, a priority and a due date, tracked in the normal bug tracker.

blameless postmortemA review that assumes everyone acted reasonably on the information they had, and looks for the system conditions that made the failure possible rather than for someone to blame. writing is what keeps people reporting their own mistakes. “The engineer ran the wrong command” invites punishment and changes nothing. “The tool ran the command against production without a confirmation or a diff” names something that can be fixed. Postmortems are reviewed, shared widely and kept searchable, so the same lesson is not learned twice.

Practise a rollback on your cluster

  1. kubectl --context kind-kx create deployment checkout --image=nginx:1.30 --replicas=3
  2. kubectl --context kind-kx set image deployment/checkout nginx=nginx:1.300
  3. kubectl --context kind-kx get pods -l app=checkout
  4. kubectl --context kind-kx rollout undo deployment/checkout
  5. kubectl --context kind-kx rollout status deployment/checkout
  6. kubectl --context kind-kx delete deployment checkout

For your own kind cluster kx: copy a command and paste it into your terminal. Run in the simulator runs the same command in this page's simulated cluster instead; nothing on this page touches your machine. The new pod stays in ImagePullBackOff while the three old pods keep serving; rollout undo returns the Deployment to nginx:1.30.

Actual state

Check your understanding

5 checks

Your first answer to each check is the one that counts. After a miss you can answer again; passing every check reconciles the lesson.

  1. Check 1 of 5

    Checkout errors jumped right after a Deployment rollout, and nobody yet knows why. What should operations do first?

  2. Check 2 of 5

    What is the incident commander's main job during a large incident?

  3. Check 3 of 5

    A runbook step runs kubectl rollout restart deployment/api -n production. Which output means the restart has finished?

  4. Check 4 of 5

    Which postmortem sentence follows blameless practice?

  5. Check 5 of 5

Lesson not yet reconciled

Desired: 4 objectives, 0 metReconciled: 4 of 4 objectives met

  • Run an incident with clear roles: incident commander, operations and communications. (not yet met)
  • Pick a severity and say what it changes about the response. (not yet met)
  • Write a blameless postmortem with a timeline, contributing factors and owned actions. (not yet met)
  • Write a runbook a tired responder can follow. (not yet met)

Pass every check above to reconcile this lesson.

Every check has passed, so the desired state is met. First-try accuracy: 0 of 5. This lesson's review cards are in your queue.

Changed since the notes

This lesson draws on an earlier set of study notes. Where the documentation contradicts a claim in them, qualifies it or has moved past it, the claim is listed here with the corrected statement and the source it was checked against.

Show 3 corrections
  1. Stale, true once, no longerIncident Management Fundamentals

    The notes saidIncident management platforms like PagerDuty, Opsgenie, or incident.io orchestrate response.

    CorrectedAtlassian ended Opsgenie sales on June 4, 2025 and ends support on April 5, 2027 (unmigrated data is deleted then). Opsgenie customers move to Jira Service Management (incident management) or Compass (alerting/on-call). Name PagerDuty, incident.io, Grafana IRM or Jira Service Management instead of Opsgenie.

    Sourceatlassian.com/blog/announcements/evolution-of-it-operations

  2. Stale, true once, no longerOn-Call Best Practices

    The notes saidPaging systems: PagerDuty, Opsgenie, and similar tools.

    CorrectedSame as note 64: Opsgenie is end-of-sale (June 4, 2025) and end-of-support (April 5, 2027); its on-call/alerting functions move to Jira Service Management or Compass.

    Sourceatlassian.com/blog/announcements/evolution-of-it-operations

  3. Wrong, not trueRunbooks and Playbooks

    The notes saidExpected output 'Deployment restarted successfully' for kubectl rollout restart.

    Correctedkubectl rollout restart deployment/api -n production prints deployment.apps/api restarted (the printer operation is 'restarted'). It only patches the pod template annotation; verify completion with kubectl rollout status deployment/api -n production, which ends with deployment "api" successfully rolled out and exits non-zero if the progress deadline is exceeded.

    Sourcegithub.com/kubernetes/kubectl/blob/master/pkg/cmd/rollout/rollout_restart.go%20;%20https://kubernetes.io/docs/concepts/workloads/controllers/deployment

Every correction across the guide, by note and topic.

Sources

Checked against kubernetes.io and the Google SRE books for Kubernetes 1.37 on .

  1. sre.google/sre-book/managing-incidents
  2. sre.google/sre-book/postmortem-culture
  3. sre.google/sre-book/being-on-call
  4. sre.google/workbook/incident-response
  5. sre.google/workbook/postmortem-culture
  6. sre.google/workbook/on-call
  7. kubernetes.io/docs/reference/kubectl/generated/kubectl_rollout/kubectl_rollout_undo
  8. kubernetes.io/docs/reference/kubectl/generated/kubectl_rollout/kubectl_rollout_restart
  9. kubernetes.io/docs/concepts/workloads/controllers/deployment
  10. kubernetes.io/docs/reference/command-line-tools-reference/kube-apiserver

Incident response and postmortems

↓ ↑ step, 1 to 6 scene, Esc leave

kind cluster kxLast command: Nothing run yet