The last week before a round is for finding out what you can do under a clock, not for covering new ground. You have the chapters behind you. What is left is speaking, timing and the few gaps that a timed run shows up.
A timed mock tells you more than rereading. You answer a prompt aloud inside a fixed time box, then score yourself against a rubric. Five prompts follow, each with a model answer and a rubric, and the rubric is the five signals from the first chapter: evidence before action, scope and blast radius, reversible change, trade-offs with numbers, and communication. That chapter names the signals and sets no scale, so this one adds a simple one: 0, 1 or 2 points for each signal. The score shows which signal you skip, and that tells you which chapter to open.
The plan below is a suggestion from this course, not a statement about how any company runs its loop. Shorten it to fit the days you have.
Day
Do
Why
7 days out
Run the whole mock cold and score it
You need a baseline before you study
6
Reread the chapter behind your weakest signal and rerun its commands
A command you have seen run is easier to explain
5
Redo your two lowest prompts aloud, timed
Practise the answer, not the reading
4
Write four story cards and tell each in 90 seconds
Speaking a story is the skill
3
Reread the job post and weight the chapters it leans on
Time goes where the role is
2
Run the mock again and compare the two scores
It shows progress and what is still weak
1
Check the machine and the notes, then stop early
Sleep helps more than a last topic
Learn no new tool in the last two days. A tool you half know invites questions about how it works.
Setting up, and the day itself
Set up once and check it. If the round is remote, open the terminal and editor you would use, make the font readable on a shared screen, and keep a plain text file for notes. Run the lab check from the first chapter on the machine you will use. Ask the recruiter which tools and references are allowed; even a short answer is information you did not have.
On the day, make your thinking visible with three habits. Say the step you are taking. Say why. Say what result would change your plan. For example: "I will check whether the errors come from one host, because if they do I can take that host out of service and look at it calmly."
Ask for time when you need it. "Let me take a minute to organise this" is a normal request. If the question is unfamiliar, say what you do know, ask a clarifying question and begin with the first step of the method that fits: the triage loop for a fault, the design loop for a design, the change loop for a risky change.
Plan the clock too. A 20-minute prompt goes further when you spend it in the same proportions each time. The model answers in this chapter use the split below, scaled for the other prompts.
Minutes of 20
What you do
What it shows
3
Ask opening questions and state assumptions
Scope and blast radius
8
Gather evidence and test the likeliest cause
Evidence before action
4
Choose a mitigation you can undo
Reversible change
3
Verify, and say what you would write down
Evidence, communication
2
Summarise in three sentences
Communication
Running the mock as a schedule
Run the mock alone, with a timer and a phone to record yourself. Read the prompt, start the timer and speak as if the interviewer were in the room, including the questions you would ask. When the time box ends, stop. Then read the model answer, open the lab output it points to, and score yourself before you read the next prompt.
Five prompts of 20, 25, 20, 20 and 15 minutes add up to 100 minutes of speaking. The script below prints the start and end of each prompt for a start time you give it.
ts
// node schedule.mts 10:00 -> start times for the five timed promptsconst start = process.argv[2] ?? '10:00'const prompts: [string, number][] = [
['Prompt 1: 502s behind a load balancer', 20],
['Prompt 2: a keyless, gradual pipeline', 25],
['Prompt 3: pods crash-looping', 20],
['Prompt 4: a burn-rate page at night', 20],
['Prompt 5: a change you rolled back', 15],
]
const BREAK = 5let t = +start.slice(0, 2) * 60 + +start.slice(3)
const two = (n: number) => String(n).padStart(2, '0')
const hhmm = (m: number) => `${two(Math.floor(m / 60))}:${two(m % 60)}`let used = 0for (const [name, mins] of prompts) {
const span = `${hhmm(t)}-${hhmm(t + mins)}`
console.log(`${span} ${String(mins).padStart(2)} min ${name}`)
t += mins + BREAK
used += mins
}
const breaks = prompts.length - 1
console.log(`${used} min timed, ${breaks} breaks of ${BREAK} min,`
+ ` ends ${hhmm(t - BREAK)}`)
schedule.mts: the five time boxes, with a 5-minute break between
text
10:00-10:2020 min Prompt 1: 502s behind a load balancer
10:25-10:5025 min Prompt 2: a keyless, gradual pipeline
10:55-11:1520 min Prompt 3: pods crash-looping
11:20-11:4020 min Prompt 4: a burn-rate page at night
11:45-12:0015 min Prompt 5: a change you rolled back
100 min timed, 4 breaks of 5 min, ends 12:00
Output of: node schedule.mts 10:00
With four 5-minute breaks, the run from 10:00 ends at 12:00. If you have less time, run prompts 1, 2 and 4 one day and 3 and 5 another.
Keep a log: the date, five scores and one change for next time. The last lesson turns the scores into a table.
Why does the plan add no new tools in the last two days?
A half-known tool invites questions you cannot answer.
The time is better spent on what you can already explain.
In a 20-minute prompt, how many minutes go to evidence and testing, and what follows?
About 8 minutes, then about 4 for a mitigation you can undo, 3 to verify and 2 to summarise.
The first 3 minutes go to questions and assumptions.
What are the three habits of thinking aloud?
Say the step, say why you take it, and say what result would change your plan.
They let the listener follow and credit your reasoning even when you do not finish.
Part 2 · Prompt 1: a third of requests return 502
The prompt and the first three minutes
Prompt, 20 minutes. "Since 14:10 about one request in three to the orders service returns a 502. The service runs on three hosts behind a load balancer. You are on call and have a shell on every host. Walk me through it."
This prompt draws on the Linux chapter and on the triage loop from the first chapter: observe, hypothesise, test, mitigate, verify. It asks whether you start with questions, narrow the scope before touching anything, and pick a fix you can undo. Spend the first three minutes on questions that each change what you do next.
What changed around 14:10: a deploy, a config edit, a certificate, a traffic spike?
Is it one host or all three, and is the share steady or growing?
What does the load balancer check, and what does it count as a failure?
Is there a rollback, or a way to take one host out of service now?
Notice what you have not done: restarted anything or named a cause. A third of requests failing across three hosts is a hint that one host is bad. It is a hint and not evidence, and the first step is to turn it into evidence.
A model answer
Observe. "A third is what I would expect if one of three hosts fails every request and the balancer spreads requests evenly. I will send a batch of requests through the balancer and count status codes by host. If the 502s come from one host, the scope is one host and my fix has a small blast radius."
Hypothesise. "A 502 means the host answered quickly with an error, or the balancer got no good answer from it. A hung host would more likely give a timeout. Likely causes are a dependency the host cannot reach, bad config on that host only, or a full disk. Config drift on one host fits, because the others work."
Test. "I read the last lines of that host's service log, check that its dependency port answers, and compare its command line with a healthy host. All of that is read-only. I also look at the health check, because the balancer kept sending traffic to a broken host, so the check must be passing."
Mitigate. "I take the host out of the balancer. That is reversible: I keep a copy of the pool list and put it back with one command. The other two hosts must carry half as much traffic again, so I check their load first. If they are near their limit, draining turns a partial failure into a full one, and I would look at rolling back the last change instead."
Verify and close. "I send the same batch again and expect no 502s, fix the config, test the host directly, and only then return it. In summary: one host of three, its database setting differed, I drained it, fixed it and restored it. Follow-ups: a health check that tests the dependency, and no hand edits to host config."
What the lab shows
The lab runs three small backends and a round-robin balancer on this machine. Host-c is started with a database address that nothing listens on. The balancer reads its pool from a file on every request, which stands in for a real target list. Counts per host can differ by one between runs.
bash
# Nine requests through the load balancer, counted by status and host.
tally() {
for i in $(seq 9); do
curl -s -o /dev/null -w '%{http_code} %header{x-backend}\n' \
127.0.0.1:55940/orders
done | sort | uniq -c
}
common.sh: nine requests, counted by status and host
text
$ tally # nine requests through the load balancer
3200 host-a
3200 host-b
3502 host-c
Observe: one host owns every 502
Three of nine requests failed, all from host-c. That turns "a third" into "one host". Now the test steps.
text
$ curl -s -w "status %{http_code}\n"127.0.0.1:55943/health
ok
status 200
$ journalctl --user -u lab-c -o cat -n 3
orders failed: ConnectionRefusedError(111, 'Connection refused')
access "GET /orders HTTP/1.1"502 -
access "GET /health HTTP/1.1"200 -
$ nc -zv -w 2127.0.0.255944 # the database host-a uses
Connection to 127.0.0.255944 port [tcp/*] succeeded!
$ nc -zv -w 2127.0.0.255945 # the database host-c uses
nc: connect to 127.0.0.2 port 55945 (tcp) failed: Connection refused
$ diff <(ps -o args= ... host-a) <(ps -o args= ... host-c)
1c1
< /usr/bin/python3 api.py HOST PORT 127.0.0.2:55944
---
> /usr/bin/python3 api.py HOST PORT 127.0.0.2:55945
Test: the health check, the log, the dependency, the command line
The health endpoint on host-c answers 200, so the balancer sees a healthy host. This is a shallow health check: it proves the process is up and says nothing about its dependencies. The journal names the cause, ConnectionRefusedError. The database port the other hosts use answers and the one host-c uses does not, and the masked command lines differ only in the last digit of that port.
text
$ cp backends.txt backends.txt.bak
$ grep -v host-c backends.txt.bak > backends.txt
$ tally # after draining host-c
5200 host-a
4200 host-b
$ # fix the config: host-c gets the port the others use
$ curl -s -o /dev/null -w "%{http_code}\n"127.0.0.1:55943/orders
200
$ cp backends.txt.bak backends.txt; tally
3200 host-a
3200 host-b
3200 host-c
Mitigate and verify: drain, fix, test directly, return
After the drain, nine requests all succeed on the two good hosts. The fix gives host-c the same database address as the others, a direct request returns 200, and after it rejoins the hosts share nine requests evenly. A real balancer uses deregistration or a zero weight, but the order is the same: contain, fix, test, restore.
Rubric and follow-ups
Score each signal 0 (not shown), 1 (partly) or 2 (clearly).
Signal
A clear answer here
Evidence before action
Counts statuses by host and reads the log before any change
Scope and blast radius
Finds one host of three; checks spare capacity before draining
Reversible change
Copies the pool, drains one host, restores it with one command
Trade-offs with numbers
Says each good host takes half as much traffic again; weighs a deep health check against a shared outage
Communication
Narrates, states assumptions, ends with a three-sentence summary
Follow-up: why did the balancer keep sending traffic to the broken host?
Its health check hits an endpoint that answers 200 whenever the process is up, so it never tests the database.
A deeper check ejects the host, but if the shared database fails it can mark every host unhealthy at once.
Follow-up: what if all three hosts return 502?
The scope is shared, so look at what the hosts have in common: the last change, the database, the network.
Roll back the last change if it lines up with the first error. Draining would remove capacity.
Follow-up: why not restart host-c straight away?
A restart loses the log context, and the service would return with the same wrong setting.
Read-only checks cost seconds and keep the evidence.
Part 3 · Prompt 2: a keyless pipeline with a canary
The prompt and how to split 25 minutes
Prompt, 25 minutes. "A team runs an orders API as a service on Amazon ECS behind a load balancer. Design the pipeline that takes a merged change to production. Deploys must use no stored cloud keys, releases must be gradual, and a bad release must roll back without a person."
This is a design prompt, so the design loop from the first chapter fits: requirements, constraints, design, failure modes, rollout. It draws on the pipelines chapter for stages and release strategy, the security chapter for supply-chain checks, the observability chapter for what triggers a rollback, and the infrastructure-as-code chapter for reviewing service settings.
Minutes of 25
What you do
4
Requirements and assumptions: deploys per day, what "bad" means, the error budget
5
Stages: build once, promote one digest, checks before each environment
5
Keyless access: the identity token, the role, the conditions that pin it
5
Release: canary size, bake time, the signal that rolls back
3
Failure modes: stolen credential, stuck approval, a change that cannot roll back
3
Numbers and summary
State two assumptions before you draw anything: an availability target (this lesson uses 99.9% over 30 days, a budget of 43.2 minutes of full outage) and that schema changes are staged so both versions of the code can run.
A model answer
Stages. "I build the image once on the merge, record its digest and pass only the digest to later stages. A tag can move; a digest cannot."
Keyless. "The workflow asks the CI system for a short-lived identity token and trades it for temporary cloud credentials, so there is no stored key. The trust policy checks the audience and the subject, and I pin the subject to the production environment, so a job from a branch, a pull request or another repository is refused. Each environment has its own role and approval rule."
Release. "A canary: 10 percent of traffic to the new revision, a 10-minute bake, then the rest. The rollback signal is the fast-burn alert on the service objective, so no new definition of bad is invented during a release."
A catch worth saying aloud. "The circuit breaker is documented for the rolling deployment type only, so it is not the rollback mechanism for a canary. The canary page lists a CloudWatch alarm that triggers rollback among its practices. The page for the alarms setting ties it to the ECS deployment controller and does not name strategies. So I would put the fast-burn alarm on the service, and prove on a test service that a failing canary rolls back before I promise it. The fallback is a lifecycle hook that runs my own check."
Failure modes and numbers. "A stolen identity token is useless without the right audience and subject, and the credentials it buys last one hour by default. A change that cannot roll back, such as a column drop, is staged: add, backfill, deploy, and drop only when no old code runs. If a release fails every request it serves, a 10 percent canary with a 10-minute bake costs about one minute of full outage, a little over 2 percent of a 43.2-minute budget. Everything at once, noticed after 10 minutes, costs nearly a quarter."
What the lab shows
Nothing here touches a cloud account. Both files are checked by static linters. The workflow builds once, exposes the digest as a job output and deploys to production only after staging. The build step calls a script that prints a digest=... line; the script is not part of the lab.
release.yml, part 2: production, after staging, by digest
text
actionlint exit 0
Output of actionlint over the whole file
The staging job, not shown, has the same shape. The file default is read-only, and each job that needs a token adds id-token: write. A second linter, zizmor, audits workflows for security problems and reported one kind of finding, six times:
Output of zizmor 1.32.0 --offline, filtered (last line wrapped)
Each finding is an action named by a version tag and not a full commit hash; the security chapter explains pinning. The six suppressed findings, shown with --persona pedantic, are three permission blocks without a comment and three jobs without a name.
The lint of this excerpt is clean. It confirms that the fields exist and their values are valid; it does not show that ECS applies the alarm to a canary. To show that it checks these fields, a copy with a misspelled strategy and a canary share of 500 was linted too (the file name and line numbers are omitted):
text
E3030 'CANRY' is not one of ['ROLLING', 'BLUE_GREEN', 'LINEAR',
'CANARY']
E3034 500 is greater than the maximum of 100
Output of cfn-lint over the broken copy (first line wrapped)
ts
// Worst case for a release that fails every request it serves: the// share of a 30-day error budget spent before the first bake time// ends and the rollback starts (rollback taken as instant).const SLO = 0.999const BUDGET_MIN = 30 * 24 * 60 * (1 - SLO) // 43.2 min of full outagetype Plan = { name: string; share: number; minutes: number }
const plans: Plan[] = [
{ name: 'all at once, noticed after 10 min',
share: 1.0, minutes: 10 },
{ name: 'canary 5%, bake 10 min', share: 0.05, minutes: 10 },
{ name: 'canary 10%, bake 10 min', share: 0.1, minutes: 10 },
{ name: 'linear first step 10%, wait 6 min',
share: 0.1, minutes: 6 },
]
console.log('plan'.padEnd(36), 'outage-min', 'budget')
for (const p of plans) {
const lost = p.share * p.minutes
const pct = (100 * lost) / BUDGET_MIN
console.log(
p.name.padEnd(36),
lost.toFixed(1).padStart(10),
`${pct.toFixed(1)}%`.padStart(7),
)
}
exposure.mts: worst-case budget spent before the first rollback
text
plan outage-min budget
all at once, noticed after 10 min 10.023.1%
canary 5%, bake 10 min 0.51.2%
canary 10%, bake 10 min 1.02.3%
linear first step 10%, wait 6 min 0.61.4%
Output
The model assumes that a bad release fails every request it serves and that rollback is instant, so the figures are upper bounds for the first stage. For the rolling alternative, the default circuit breaker threshold is half the desired count, rounded up, within 3 to 200, so a service of 12 desired tasks fails the deployment after 6 failed tasks. The pipelines chapter works this rule in code.
Rubric and follow-ups
Score each signal 0 (not shown), 1 (partly) or 2 (clearly).
Signal
A clear answer here
Evidence before action
Defines "bad" before the release (an alert on the objective); promotes only a tested artifact
Scope and blast radius
Canary, a role per environment, subject pinned to production
Reversible change
Names the rollback trigger, keeps the old revision during the bake, stages irreversible database changes
Trade-offs with numbers
Compares canary sizes against a stated error budget
Communication
States assumptions first and flags what is unconfirmed
Follow-up: why a digest and not the tag latest?
A tag can be moved to a different build, so what you tested may not be what you deploy.
A digest is a hash of the contents, recorded once after the build.
Follow-up: how would a rolling update change your rollback answer?
The circuit breaker would fail the deployment when new tasks cannot start, at 6 failed tasks for 12 desired.
It sees tasks failing to start, not errors from tasks that run, so it does not replace an alert on the objective.
Follow-up: a memory leak appears an hour after a clean canary. What changes?
Lengthen the bake or add a stage, and pay for it in slower releases.
Keep the old revision running through the bake so rollback stays quick.
Part 4 · Prompt 3: pods restart after a config change
The prompt and what to ask
Prompt, 20 minutes. "At 16:20 a change to the orders Deployment went out. Since then the pods restart about every minute, the restart count climbs, and some pods show CrashLoopBackOff. The service answers some requests. Walk me through it. You have the manifests from before and after."
This prompt draws on the Kubernetes chapter: container states, exit codes, probes, rollouts and the back-off schedule. There is no cluster in this course, so the commands in the answer are the ones you would run, and the lab works on the manifests. Open with questions:
What changed at 16:20: the image, environment, ports, probes or resources?
How many pods are affected, and is the new ReplicaSet the one restarting?
What exit code does the last state show, and what do the events say?
Can I roll back to the previous revision now?
The exit code is the best single clue. A container ended by a signal reports 128 plus the signal number, so 137 is SIGKILL and 143 is SIGTERM. Exit 137 with the reason OOMKilled points at the memory limit. Exit 143 means something asked the container to stop, in a pod usually the kubelet acting on a failed probe. A small code such as 1 or 2 means the application chose to exit, and the previous container's log should say why.
A model answer
Observe. "I read the pod's last state, exit code and events, then the previous container's log with --previous, because the current container is usually empty. I compare the two manifests, since the symptom started with a change."
Hypothesise. "Three likely causes. A probe that no longer matches the application, because probes are easy to forget when a port changes. A memory limit too low for the new version. A start-up error, such as a missing variable. The change touched the port, so I suspect the probes."
Test. "I compare the ports in the manifest: the variable the app reads, the container port and the port each probe checks. A liveness probe on a port the app no longer uses fails every time, and after the failure threshold the kubelet restarts the container. If readiness was updated and passes, the pod looks Ready and the rollout completes, so rollout status can report success while the pods keep restarting."
Mitigate. "It is a Deployment template change, so kubectl rollout undo deployment/orders returns to the previous revision, and the Deployment keeps ten revisions by default. That is reversible, quick and narrow. I would not raise the liveness threshold, which hides the fault, and I would not delete pods, because new pods would fail the same way."
Verify and close. "I watch the restart count stop, the pods stay Ready past the liveness window and the error rate recover. Then I fix forward: change the port everywhere it appears and add a check to the pipeline. The schema check passed on both versions, so a check that reads ports and probes together would have caught this in the pull request."
What the lab shows
The two manifests describe one Deployment. The change moved the application from port 8080 to 9090. It updated the PORT variable, the container port and the readiness probe, and missed the liveness probe.
Schema validation against Kubernetes 1.37 passes on both files, because a probe on port 8080 is valid YAML.
text
INFO manifests/before.yaml passed for resource deployment/orders
against version 1.37
INFO manifests/after.yaml passed for resource deployment/orders
against version 1.37
Output of kubernetes-validate 1.37.0 --strict (lines wrapped)
A check that reads ports and probes together finds it. It lists each container's declared ports and reports an HTTP probe on a port that is not among them.
ts
import { readFileSync } from'node:fs'import { parseAllDocuments } from'yaml'// Does each probe point at a port the container declares?let problems = 0for (const file of process.argv.slice(2)) {
const docs = parseAllDocuments(readFileSync(file, 'utf8'))
.map((d) => d.toJS())
for (const d of docs.filter((x) => x.kind === 'Deployment')) {
for (const c of d.spec.template.spec.containers) {
const ports = (c.ports ?? []).map((p: any) => p.containerPort)
for (const kind of ['readinessProbe', 'livenessProbe']) {
const port = c[kind]?.httpGet?.port
if (port !== undefined && !ports.includes(port)) {
console.log(`${file}: ${d.metadata.name}/${c.name} ${kind}` +
` checks port ${port}, container declares ${ports}`)
problems++
}
}
}
}
}
if (!problems) console.log('ok: every probe port is a declared port')
process.exitCode = problems ? 1 : 0
probe-check.mts
text
ok: every probe port is a declared port
manifests/after.yaml: orders/api livenessProbe checks port 8080,
container declares 9090
Output: the before file, then the after file (line wrapped)
The check is narrow: it knows only what the manifest declares, and it compares numbers, so a probe that names its port would be reported. It needs no cluster.
The restart pattern can be modelled. With a probe every 10 seconds and 3 failures in a row, the kubelet restarts the container after about 30 seconds, and the delays between restarts double from 10 seconds to a cap of 300, as the Kubernetes documentation describes. This is arithmetic on those numbers, not a cluster run.
Output of cycle.mts: start, kill time and wait for each run
By the sixth start, 460 seconds in, the pod waits 300 seconds between runs. Deleting pods does not help, because each new pod begins its own sequence.
Rubric and follow-ups
Score each signal 0 (not shown), 1 (partly) or 2 (clearly).
Signal
A clear answer here
Evidence before action
Reads exit code, events and previous log, and compares the manifests first
Scope and blast radius
Asks which pods and ReplicaSet restart; notes the rollout completed, so all new pods are affected
Reversible change
Rollout undo to the previous revision; refuses to loosen the probe or delete pods
Trade-offs with numbers
Uses the back-off schedule and the probe timing to say how long recovery would take
Communication
Separates what the manifests prove from what a cluster would show
Follow-up: rollout status said success. How can the pods still restart?
Rollout progress depends on pods becoming Ready, and the updated readiness probe passed.
The liveness probe is a separate check that ran afterwards and restarted the containers.
Follow-up: the exit code is 137 with the reason OOMKilled. What changes?
The cause is the memory limit, not the probe. Check what grew in the release and whether the limit fell.
Raise the limit only after checking for a leak. The Linux chapter showed the same oom-kill on the kernel side.
Follow-up: why not lengthen the liveness delay to stop the restarts?
It hides the broken probe and slows detection of a real hang.
Fix the probe port; use a startup probe if the app is slow to start.
Part 5 · Prompt 4: a burn-rate page at 02:01
The prompt and the first minutes
Prompt, 20 minutes. "At 02:01 you are paged: the fast-burn alert on the checkout objective has fired. The objective is 99.9% of checkouts succeeding over 30 days. You are on call. What do you do, from the page to the written review?"
This prompt draws on the observability chapter for the alert and the error budget, and on the incidents chapter for declaring, roles, mitigation, updates and the review. It tests order: decide what kind of problem this is before you start fixing.
Minutes of 20
What you do
3
Acknowledge, confirm the alert is current, measure the scope
3
Declare, set a severity, name the roles
6
Mitigate: one fast, reversible, narrow action; capture evidence first
4
Update people: what users see, what you do, when you update next
4
Close: the watch period and a blameless review outline with numbers
An alert on error-budget burn tells you how fast the budget is going, not why. The burn rate is the error rate divided by the budget fraction. With a 99.9% objective the fraction is 0.001, so a 5% error rate is a burn rate of 50, and at that rate a month of budget lasts about 14 hours.
A model answer
Observe. "I acknowledge the page and check the alert is current: the short window is there so that a firing alert means the problem is still happening. I ask what changed recently, how many checkouts fail and whether it is one region or one dependency."
Declare. "Customers cannot pay and a fix may need another team, so I declare. By the severity table from the incidents chapter, about 5 percent of a core action failing is severity 2. I name a commander, an operations person and a communications person, or say that I hold all three and page the others."
Mitigate. "I capture two minutes of evidence first: error rate by endpoint, the last change, recent log lines. Then I choose a mitigation that is fast, reversible and narrow. A config push at 01:40 lines up with first errors at 01:44, and it was behind a flag. Turning the flag off is quicker than a rollback and reaches only that behaviour. One change at a time, written in the timeline before I do it."
Communicate. "At about 02:06 the first external update goes out: what users may see, what we are doing, when the next update comes. It names no cause, because the cause is a hypothesis until the errors stop."
Close. "When the error rate is back under 0.1 percent I mark the incident mitigated and keep watching for 30 minutes, because a dip is not the end. Then the review, from the timeline: times to detect, declare, mitigate and resolve, contributing factors, action items with owners and dates. One finding is already clear: the alert fired 17 minutes after the first failure, and I would ask whether a faster signal is worth its false pages."
What the lab shows
The lab replays the night. Traffic is 1,000 checkouts a minute for four days with a background error rate of 0.02 percent. On the last day a config push at 01:40 makes 5 percent of checkouts fail from 01:44 until a flag is turned off at 02:09, so the last failing minute is 02:09. The evaluator is the one from the observability chapter, with its three rules; a small helper that prints a minute number as a clock time is left out.
ts
import { RULES, firing } from'./burn.mts'import { clock } from'./clock.mts'const PER_MIN = 1000// checkouts a minute, for four daysconst DAY4 = 3 * 1440const START = DAY4 + 104// 01:44, first failing minuteconst STOP = DAY4 + 130// 02:10, flag is off, errors stopconst total: number[] = []
const bad: number[] = []
let carry = 0for (let m = 0; m < 4 * 1440; m++) {
const rate = m >= START && m < STOP ? 0.05 : 0.0002
carry += PER_MIN * rate
const b = Math.floor(carry)
carry -= b
total.push(PER_MIN)
bad.push(b)
}
for (const rule of RULES) {
const f = firing(total, bad, 0.999, rule)
const first = f.indexOf(true)
const last = f.lastIndexOf(true)
console.log(rule.name.padEnd(11),
first < 0 ? 'never fires' : `${clock(first)} to ${clock(last)}`)
}
const budget = 30 * 1440 * PER_MIN * 0.001// failed requests allowedfor (const [label, end] of [['02:00', 120], ['02:10', 130]] asconst) {
const n = bad.slice(START, DAY4 + end).reduce((a, b) => a + b, 0)
const pct = ((100 * n) / budget).toFixed(1)
console.log(`spent by ${label}: ${n} failed, ${pct}% of budget`)
}
page.mts: build the request log, run the rules, count the cost
text
page 14.4x day 402:01 to day 402:12
page 6x never fires
ticket 1x never fires
spent by 02:00: 800 failed, 1.9% of budget
spent by 02:10: 1300 failed, 3.0% of budget
Output
Only the fast rule fires. It fires at 02:01, 17 minutes after the first failure, because the one-hour window must average above 1.44 percent errors. It stops at 02:12, three minutes after the last failing minute, because the five-minute window has to cool. The slower rules never fire. About 1.9 percent of the 30-day budget was gone at 02:00 and 3.0 percent by 02:10.
The session below declares at 02:04, names three roles, prints the first external update at 02:06, then records the mitigation and the recovery. The scripts are the incident tool and update script from the incidents chapter, run on new data.
text
--- 02:06, first external update
Some checkouts are failing: declared
What you may see: about 5% of checkouts fail.
What we are doing: looking at recent changes; a rollback is ready.
Next update by 03:06.
--- show
INC-318 SEV 2 mitigated
commander Kiran Das | ops Lata Menon | comms Rohit Bose
02:04 declared declared SEV 202:09 mitigating new-timeout flag off
02:12 mitigated error rate back under 0.1%
Output: the 02:06 update, then the record
The update names no config push, flag or cause.
text
time to detect 17 min
time to declare 20 min
time to mitigate 28 min
time to resolve 58 min
change to impact 4 min
Output of review.mts over the event file: the durations
Seventeen minutes to detect and 20 to declare are the numbers to question. The first is a property of the alert: a one-hour window needs 17 minutes of 5 percent errors to trip. A shorter window fires sooner and also fires on blips, a trade between detection time and false pages. The second is mostly the first again: the declaration came 3 minutes after the page.
Rubric and follow-ups
Score each signal 0 (not shown), 1 (partly) or 2 (clearly).
Signal
A clear answer here
Evidence before action
Confirms the alert is current, links the first errors to the 01:40 change, captures evidence first
Scope and blast radius
Measures the share of checkouts failing; sets severity from impact
Reversible change
Flag off, one change at a time, logged before it is done
Trade-offs with numbers
Uses burn rate and budget spent (about 1.9 percent at the page); weighs window length against false pages
Communication
Names roles, sends an update with no cause and a next-update time, writes the review from the timeline
Follow-up: why does the fast rule need a one-hour and a five-minute window?
The long window shows enough budget has gone. The short window shows the problem is still happening, so the alert clears soon after the fix.
In the run it cleared three minutes after the last failing minute.
Follow-up: why turn the flag off and not roll back?
Both are reasonable. The flag is faster and narrower, while a rollback touches the whole release.
Say why you chose one and keep the other ready if errors do not drop.
Follow-up: errors fall for five minutes and then rise again. What now?
Return the incident to mitigating, say so in the next update and revisit the hypothesis.
That is why the watch period exists.
Part 6 · Prompt 5: a change you rolled back, and scoring the mock
The prompt and how to prepare
Prompt, 15 minutes. "Tell me about a change you made that you had to roll back."
This prompt draws on the stories chapter and on the change loop from the first chapter: plan, verify, release gradually, roll back. It asks for something that happened to you, told in order. The answer below is built on a made-up story with invented numbers. Use a real one, with numbers from your notes, the ticket or the review.
The shape is STAR: situation, task, action, result. Spend most of the time on the actions, about 60 percent by the guide the stories chapter cites. Two card fields do the most work: the evidence you looked at before acting, and what changed in the system afterwards.
A good story here has four properties. You made the change, so ownership is yours. The rollback was your decision, with a reason. There is a number for how long it took to notice and to act. And something durable changed afterwards, such as a pipeline check. "I was more careful" is not a change to the system.
Tell it in about 90 seconds and expect follow-ups for the rest of the slot.
A model answer
Situation and task. "I owned a change to how our order consumers read from a queue. I raised the batch size to cut the time orders waited. We release such changes to 10 percent of hosts first. My job was to make orders faster and, once it went wrong, to stop the delay."
Actions. "At 14:30 I rolled the change to 10 percent of hosts. At 14:41 the canary panel showed order delay three times higher on the changed hosts. First I compared the changed hosts with the rest, to be sure it was the change and not a busy period. Only the changed hosts were slow. I proposed a revert to the on-call lead, who agreed, and at 14:46 I reverted the setting. At 14:55 I told support which 64 restaurants had late orders, so they could call them."
Result. "Delay was normal on every host by 15:05, after 310 delayed orders. I noticed 11 minutes after the release and acted 5 minutes after the alert. Afterwards I added a load test that fails the build if delay rises 20 percent, and the team added batch size to the canary checks. The review found my change had only been tested with light traffic."
Differently. "I would run the load test before the canary. The canary did its job: it limited the harm to a tenth of the hosts."
Read it as a listener would. It says "I" for the speaker's steps and keeps the team in the result. It owns the cause without blaming anyone: the change was untested under load, a gap in the pipeline. It gives two labelled numbers, 11 minutes to notice and 5 to act, and ends on a change to the system.
Turning the story into an outline
The outline script from the stories chapter reads a timeline file and builds a 90-second outline with a 20, 10, 60 and 10 percent split. Fed the timeline of this made-up story, it shows whether the numbers come from the record and whether the balance of actions is reasonable.
text
Situation (18 s)
- A queue setting I rolled back: 310 orders delayed, 64 restaurants
- Release at 14:30, alert at 14:41
Task (9 s)
- I was the owner of the change; my job was to stop the delay
Action (54 s)
- At 14:30 I raised the consumer batch size on 10 percent of hosts
- At 14:44 I compared changed hosts with the rest; only they were slow
- At 14:46 I reverted the setting on the changed hosts
- At 14:55 I told support which 64 restaurants had late orders
Result (9 s)
- Detected 11 min after the release
- Rolled back 5 min after the alert
- Resolved at 15:05
- Afterwards (me): added a load test that fails if delay rises 20%
- Afterwards (team): wrote the review; added a canary check
115 words in the outline; at 130 words a minute,
speaking it takes about 53 s.
Actions that are mine: 4 (80% of the human steps).
Output of outline.mts story.json
The intervals come from the timestamps: 11 minutes from the change to the alert and 5 from the alert to the revert. The outline takes about 53 seconds to say at an assumed 130 words a minute, which leaves about 35 seconds for the reasoning the bullets omit: why you compared hosts first, and why you reverted and did not fix forward. The share of actions that are yours is 80 percent. A figure of 100 would suggest you leave out the people who helped.
The script cannot judge whether a story is true or tell you what you left out. It guards against three failures: no numbers, no personal actions and no follow-up.
Scoring the whole mock
After the five prompts, put the scores in one table. Each prompt gets 0, 1 or 2 for each of the five signals, so the maximum is 50. The numbers below are made up to show the output. There is no pass mark: the table shows which signal you skip.
import { readFileSync } from'node:fs'// Each signal: 0 not shown, 1 partly, 2 clearly, one score per prompt.const sheet = JSON.parse(readFileSync(process.argv[2], 'utf8'))
const names: string[] = sheet.prompts
const rows = Object.entries<number[]>(sheet.scores)
const sum = (xs: number[]) => xs.reduce((a, b) => a + b, 0)
const head = names.map((n) => n.slice(0, 5).padEnd(6)).join('')
console.log('signal'.padEnd(26), head, 'total')
for (const [signal, xs] of rows) {
const cells = xs.map((x) => String(x).padEnd(6)).join('')
console.log(signal.padEnd(26), cells, `${sum(xs)}/${2 * xs.length}`)
}
const grand = sum(rows.flatMap(([, xs]) => xs))
const max = rows.length * names.length * 2
console.log(`\nmock total ${grand}/${max}`)
const byTotal = [...rows].sort((a, b) => sum(a[1]) - sum(b[1]))
const [weak, wxs] = byTotal[0]
console.log(`weakest signal: ${weak} (${sum(wxs)}/${2 * names.length})`)
const zeros = rows.flatMap(([s, xs]) =>
xs.flatMap((x, i) => (x === 0 ? [`${s} in "${names[i]}"`] : [])))
console.log('not shown at all:')
for (const z of zeros) console.log(' ' + z)
if (!zeros.length) console.log(' nothing')
score.mts: totals, the weakest signal, the zeros
text
signal 502s pipel crash burn rollb total
Evidence before action 212218/10
Scope and blast radius 221117/10
Reversible change 122229/10
Trade-offs with numbers 010113/10
Communication 221128/10
mock total 35/50
weakest signal: Trade-offs with numbers (3/10)
not shown at all:
Trade-offs with numbers in "502s"
Trade-offs with numbers in "crash loop"
Output of: node score.mts scores.json
The total of 35 is only useful against your next run. The weakest signal is trade-offs with numbers, 3 of 10, and the two zeros are the prompts where no number was spoken. The weak spot is a habit, not knowledge: say a number.
If the weakest signal is
Reread
Then practise
Evidence before action
The Linux chapter and the triage loop in the first chapter
Prompts 1 and 3, spending the first minutes only on questions
Scope and blast radius
The Linux and Kubernetes chapters
Say how many hosts or users and what your fix could touch
Reversible change
The pipelines and infrastructure-as-code chapters
Prompt 2, naming the way back for each step
Trade-offs with numbers
The observability and cost chapters
Put one figure in every answer: a budget, a threshold, a price
Communication
The incidents and stories chapters
Record yourself and count silences and missing summaries
Follow-up: why did you roll back and not fix forward?
The cause was likely, the revert was quick and narrow, and a fix needed time under load while orders were late.
Fixing forward is fair when the revert is itself risky, such as after a data change; say which case you were in.
Follow-up: how did you know the change caused it?
I compared changed hosts with unchanged ones at the same time. Only the changed ones were slow, so a busy period was ruled out.
The canary design means both groups see the same traffic.
Follow-up: a mock total of 38 out of 50. Is that a pass?
There is no pass mark. Compare it with your earlier run and look at the weakest signal.
Two runs with the same weak signal tell you what to practise next.