The idea in one minute#
When you are paged, your job is not to find the root cause. It is to stop the user pain, as safely and quickly as possible. The order is: acknowledge → assess impact → ask “what changed?” → mitigate → then understand. Most incidents are caused by a change — a deploy, a config push, a flag, a traffic shift — so undoing the most recent change is the most effective first move. Debugging comes after users are fine.
When the problem is not a change, a fixed checklist beats intuition: the USE method on the hosts, a short list of Linux commands, a short list of Kubernetes commands.
An analogy#
A paramedic arriving at an accident stops the bleeding before asking how the crash happened. The investigation matters — later, with the patient stable.
A picture#
flowchart TB
P[":pagerduty: Paged"] --> ACK["1 · Acknowledge<br/><small>within 5 min</small>"]
ACK --> IMP["2 · Impact<br/><small>SLO dashboard: who, how bad, since when</small>"]
IMP --> BIG{"Big or<br/>spreading?"}
BIG -->|"yes"| DECL[":i-siren: Declare an incident<br/><small>get help now (5.a)</small>"]
BIG -->|"no"| CH
DECL --> CH["3 · What changed?<br/><small>deploys, config, flags, traffic, dependencies</small>"]
CH --> MIT["4 · Mitigate<br/><small>rollback, flag off, drain, scale, fail over</small>"]
MIT --> OK{"Users OK?"}
OK -->|"no"| DIAG["Diagnose<br/><small>USE, Linux, Kubernetes checklists</small>"] --> MIT
OK -->|"yes"| AFTER["5 · Understand, write up,<br/>hand over"]
class P warn
class ACK,IMP,CH queue
class BIG,OK queue
class DECL warn
class MIT compute
class DIAG memory
class AFTER ioHow it really works#
1. Acknowledge#
Ack the page so it does not escalate, and say in the team channel that you are looking. One line: “Looking at CheckoutErrorBudgetBurnFast.”
2. Assess impact#
From the SLO dashboard and the alert:
- Who is affected — all users, one region, one customer, one feature?
- How bad — error ratio, latency, how fast the budget is burning?
- Since when — the start time is the anchor for “what changed?”
- Getting worse?
If it is big, spreading, involves data loss or security, or you are not making progress in 15 minutes — declare an incident and get help (5.a). Declaring early is cheap; a lone engineer struggling for an hour is expensive.
3. What changed?#
Look at everything that changed shortly before the start time:
| Kind of change | Where to look |
|---|---|
| Code deploys | Deploy log / CI, kubectl rollout history, Argo CD history |
| Config pushes | Config repo history, config service audit log |
| Feature flags | Flag platform audit log |
| Infrastructure | Terraform applies, cloud console audit log (CloudTrail etc.) |
| Traffic | Request rate by client — a new client, a bot, a marketing push, a retry storm |
| Dependencies | Their status pages and dashboards, your error logs by upstream |
| Time | Cron jobs, certificate expiry, daylight-saving changes, month-end batch |
A shared change log — every deploy, flag flip and config push in one stream, timestamped — is one of the highest-value tools an SRE team can build.
4. Mitigate: the generic mitigations#
These work without knowing the root cause:
| Mitigation | When | Risk |
|---|---|---|
| Roll back the latest deploy | Started after a deploy | Low — if rollbacks are routinely practised and the DB schema is compatible |
| Turn off a feature flag | Started after a flag change | Low |
| Drain a zone, region, or bad host | Failure is localised | Remaining capacity must cope |
| Scale up | Saturation from real demand | Does nothing for a bug; can overload a shared dependency |
| Fail over to a replica or secondary provider | A dependency is down | Failover itself can fail; split brain for databases |
| Shed load / rate-limit a client | One client or traffic class is overloading | That client is hurt on purpose |
| Restart | Memory leak, stuck process | Destroys evidence; take a heap or goroutine dump first if cheap |
| Block bad traffic at the edge | Attack, broken client | Collateral blocking |
Prefer mitigations that are reversible and that you have done before.
5. Diagnose when it is not a change#
Linux, the first 60 seconds — Brendan Gregg’s checklist, still the best:
uptime # load averages: rising, falling?
dmesg -T | tail # OOM kills, disk errors, TCP drops
vmstat 1 5 # r (run queue) > cores? si/so (swapping)? wa (I/O wait)?
mpstat -P ALL 1 3 # one hot CPU = a single-threaded bottleneck
pidstat 1 3 # which process uses the CPU
iostat -xz 1 3 # await, %util per disk
free -m # available memory (not "free")
sar -n DEV 1 3 # network throughput vs link speed
sar -n TCP,ETCP 1 3 # retransmits, connection rates
top # overview; check what you saw abovePlus the ones that catch the classic outages:
df -h; df -i # disk space AND inodes
ss -s; ss -tanp | head # socket states; thousands in TIME_WAIT or CLOSE_WAIT?
journalctl -u myservice --since "15 min ago" | tail -50
cat /proc/$(pgrep -n myservice)/limits | grep -i "open files"; ls /proc/$(pgrep -n myservice)/fd | wc -lKubernetes, the first commands:
kubectl -n payments get pods -o wide # restarts? Pending? which nodes?
kubectl -n payments describe pod checkout-7d9c-abcde # events: OOMKilled, probe failures, image pull
kubectl -n payments logs checkout-7d9c-abcde --previous # logs of the crashed container
kubectl -n payments get events --sort-by=.lastTimestamp | tail -20
kubectl -n payments rollout history deploy/checkout
kubectl -n payments top pods # CPU / memory vs limits
kubectl get nodes; kubectl describe node <node> | grep -A5 Conditions # MemoryPressure, DiskPressureGo services: if the service exposes net/http/pprof, grab a goroutine dump before
restarting — it shows exactly where every goroutine is blocked:
curl -s localhost:6060/debug/pprof/goroutine?debug=2 > goroutines.txt
go tool pprof -top http://localhost:6060/debug/pprof/heapWrite as you go#
Keep a timestamped log in the incident channel: what you saw, what you did, what happened. It costs seconds, helps anyone joining, and makes the postmortem easy.
02:14 paged CheckoutErrorBudgetBurnFast, 6% errors all regions
02:17 deploy checkout v2026.10.20-3 at 01:52 (dep update). Rolling back.
02:21 error ratio 0.05%. Mitigated. Will look at the diff in the morning.A worked example#
A page at 10:40: p99 latency on the orders API is 8 s (normally 200 ms). No deploys today.
- Impact: all regions, all routes, error ratio rising (timeouts). Declare SEV-2.
- What changed? No deploys, no flags. Traffic is normal. The change log shows a Terraform apply at 10:31 — “rotate DB credentials”. Suspicious, but credentials do not cause slowness.
- Diagnose:
kubectl top pods: CPU low. Logs:pq: sorry, too many clients already. The new credentials have a connection limit of 50 in the database’s role config; the old ones had 500. Connection pools are queuing. - Mitigate: raise the role’s connection limit to 500 (one SQL statement, reversible). Latency back to normal at 10:52.
The program below is a small “what changed?” assistant: given the incident start and the change log, it ranks changes by how suspicious their timing is.
Code#
// whatchanged.go — rank recent changes by suspicion relative to an incident start time.
package main
import (
"fmt"
"math"
"sort"
"time"
)
type change struct {
at time.Time
kind string // deploy, flag, config, infra
service string
what string
}
// suspicion is high for changes shortly before the start, decays with age, and is zero after the start.
// Changes to the affected service, or anything it depends on, weigh more.
func suspicion(c change, start time.Time, affected map[string]bool) float64 {
gap := start.Sub(c.at)
if gap < 0 {
return 0
}
s := math.Exp(-gap.Minutes() / 30) // half-ish life ~20 minutes
if affected[c.service] {
s *= 3
}
if c.kind == "config" || c.kind == "infra" {
s *= 1.5 // config and infra changes are under-reviewed relative to code
}
return s
}
func main() {
day := time.Date(2026, 10, 21, 0, 0, 0, 0, time.UTC)
at := func(h, m int) time.Time { return day.Add(time.Duration(h)*time.Hour + time.Duration(m)*time.Minute) }
start := at(10, 38)
affected := map[string]bool{"orders-api": true, "orders-db": true}
log := []change{
{at(8, 5), "deploy", "search", "search v812"},
{at(9, 50), "flag", "web", "enable new-header for 10%"},
{at(10, 12), "deploy", "recommendations", "recs v77"},
{at(10, 31), "infra", "orders-db", "terraform: rotate DB credentials"},
{at(10, 36), "deploy", "notifications", "notif v19"},
{at(10, 45), "deploy", "orders-api", "orders v300 (after start)"},
}
sort.Slice(log, func(i, j int) bool {
return suspicion(log[i], start, affected) > suspicion(log[j], start, affected)
})
fmt.Printf("incident start %s — changes ranked by suspicion\n\n", start.Format("15:04"))
for _, c := range log {
fmt.Printf("%5.2f %s %-7s %-16s %s\n", suspicion(c, start, affected), c.at.Format("15:04"), c.kind, c.service, c.what)
}
}It is deliberately simple. The value is in having one change log that includes infrastructure and config, not only code deploys.
Remember this#
- Acknowledge, assess impact, ask what changed, mitigate, then understand.
- Declare an incident early if it is big, spreading, risky, or not improving in 15 minutes.
- Generic mitigations — rollback, flag off, drain, fail over, shed — work without a root cause.
- Use checklists: USE, the Linux 60-second list, the Kubernetes first commands.
- Take a goroutine or heap dump before restarting if it is cheap. Write a timestamped log as you go.
Try it#
- Run
whatchanged.go. Add a config change toorders-apiat 10:20. Where does it rank? - On a Linux VM, run the 60-second checklist while
stress-ng --cpu 4 --io 2runs. Which command shows each problem first? - In a
kindcluster, deploy a pod with a 64 MiB memory limit that allocates 200 MiB. Find the OOM kill with the Kubernetes commands above.
Check yourself#
- Why is “what changed?” the first diagnostic question?
- Name four generic mitigations and one risk of each.
- When would scaling up make an incident worse?
- What does a high
rcolumn invmstattell you?