DevOps Engineer · Step 7 of 8 · 9 min
Monitoring, observability and incidents
Know what to measure, when to alert, and how to handle and learn from an outage.
Metrics, logs and traces
Monitoring tells you whether a system is healthy. Observability is being able to ask new questions about it when something odd happens. Both rely on three kinds of signal. Metrics are numbers over time, like requests per second or error rate. Logs are records of events. Traces follow one request across many services.
OpenTelemetry is the open standard for collecting all three. Prometheus and Grafana are common open-source tools for metrics and dashboards.
Alert on what users feel
Alert on symptoms users notice, such as errors and slow responses, not on every high CPU spike. Too many alerts teach people to ignore them.
Site reliability engineering uses service level objectives, SLOs: a target such as 99.9% of requests succeed over 30 days. The gap below 100% is the error budget. If you spend it, you slow down releases and fix reliability.
During an incident
First, stop the harm: roll back, switch off a feature flag, or add capacity. Find the root cause later. Name one person to coordinate, keep a written timeline, and tell affected users what is happening in plain words.
After an incident
Write a blameless post-incident review. Ask what happened, why it made sense to the people involved at the time, and what would stop it happening again. People make mistakes; systems should make them hard to make and easy to recover from. Track the follow-up actions until they are done.
Try it
Write a practice post-incident review
- 1.Ask a chatbot the prompt below to invent a realistic outage.
- 2.Write the timeline yourself: detection, response, fix, recovery.
- 3.List three follow-up actions, each with an owner, and make sure none of them is be more careful.
Invent a realistic outage at a small online shop caused by a bad configuration change. Give me the alerts and log lines the team saw, in order, but not the answer. I will write the timeline and root cause, then you critique my blameless post-incident review.