"AIOps" cheat sheet
"Practical rules for anomaly detection, alert grouping, incident hints and safe auto-remediation."
In the print dialog, choose "Save as PDF" as the destination.
Before you buy or build
- Write down a baseline: alerts per incident, time to acknowledge, time to find cause, false pages.
- Fix telemetry, service names and the change log first.
- Trial beside current practice for a few weeks. Keep it only if the numbers improve.
Anomaly detection ladder
| Step |
Method |
Good for |
| 1 |
Static threshold |
Hard limits such as disk full |
| 2 |
Rolling mean and spread |
Metrics without a daily pattern |
| 3 |
Seasonal baseline |
Traffic, with daily and weekly rhythm |
| 4 |
Forecast or model |
Many series, after simple methods fail |
sum(rate(http_requests_total{job="checkout"}[5m]))
/
sum(rate(http_requests_total{job="checkout"}[5m] offset 1w))
Reduce alert noise
route:
group_by: [cluster, service]
group_wait: 30s
inhibit_rules:
- source_matchers: [alertname = "NodeDown"]
target_matchers: [severity = "warning"]
equal: [cluster, node]
Root cause hints
- List changes just before the first symptom.
- Overlay dependency health.
- Rank by time gap, graph distance and size of anomaly.
- Show evidence with every hint.
- A person confirms before any production change.
preconditions: [alert_still_firing, no_active_deploy, target_count_max: 2]
limits: {max_per_hour: 2, cooldown: 30m, kill_switch: automation/global}
verify: {after: 5m, expect: "queue_depth < 100"}
on_verify_fail: page_human
Check an assistant's answer
- Ask which evidence the claim rests on, and open it.
- Turn the cause into a query you can run.
- Line up alerts, deploys and changes on one timeline.
- Record hits and misses.
- A person approves every action.
Commands for checking a claim
$ promtool query instant http://prometheus:9090 'sum(rate(http_requests_total{code=~"5.."}[5m]))'
$ git log --since="2 hours ago" --oneline
$ kubectl rollout history deployment/checkout
Official references
Read the vendor and project documentation for the full, current detail.