alert: KubeContainerOomKilled
expr: kube_pod_container_status_last_terminated_reason{reason="OOMKilled"} == 1
and on (namespace, pod, container)
increase(kube_pod_container_status_restarts_total[10m]) > 0
for: 0m
severity: warning
Alert message: Container {{ $labels.container }} was OOM-killed ({{ $labels.namespace }}/{{ $labels.pod }})
A container was restarted and the reason for its last termination was OOMKilled: the process exceeded its memory limit (resources.limits.memory). The alert is active while the restart counter has increased within 10 minutes.
A limit that is too low, a memory leak, peak load, runtime settings (JVM heap, Node.js) above the container limit.
kubectl -n <ns> describe pod <pod> # Last State: Terminated, Reason: OOMKilled
kubectl -n <ns> top pod <pod> --containers
kubectl -n <ns> get pod <pod> -o jsonpath='{.spec.containers[*].resources}'
kubectl -n <ns> logs <pod> -c <container> --previous
Increase the memory limit, bring the application settings in line with the limit, find the leak. Keep a sensible gap between requests and limits.
For test and batch jobs where OOM is expected.
The full pack of 44 tested rules + Alertmanager → Telegram: 790 ₽ (≈ $9, card payment in rubles)
Open in Telegram · Free Monitoring Lite kit · All runbook alerts