Working an OOMKilled pod: the limit, the leak or the node
OOMKilled says a container used more memory than it was allowed. Telling a limit that is too low from a leak from a node under pressure, and why raising the limit first often costs you a second outage.
How do I tell why a pod was OOMKilled?
Check whether the container went over its own memory limit or the node ran out, because the fix is different. The reason field on the last state says OOMKilled and the memory limit in the pod spec tells you what it was held to. Memory over time tells you whether this is a leak or a workload that was always too big for the limit.
First: was it the container's limit or the node?
These look similar on a dashboard and lead opposite ways. A container over its own limit is killed by itself and the rest of the node carries on. A node under memory pressure evicts whole pods to save itself, which shows as Evicted rather than OOMKilled.
kubectl get pod <pod> -n <namespace> \
-o jsonpath='{.status.containerStatuses[*].lastState.terminated.reason}'
kubectl describe node <node> | grep -A 5 ConditionsIf the node shows MemoryPressure, you have a node problem wearing a pod's clothes. Evicted pods is the reference for that path.
Then: a limit that was always too low, or a leak?
One moment of memory tells you nothing. The shape across several restarts tells you almost everything.
- Climbs steadily from each start until it hits the limit, every time, at roughly the same rate: a leak. Raising the limit moves the outage later, it does not remove it.
- Jumps to near the limit immediately and sits there: the workload needs more than it was given. Raising the limit is the fix.
- Normal for hours then spikes: something about the input changed. A large request, a backfill, a retry storm.
Why raising the limit first is usually the wrong move
It is the fastest thing to do and it is the reason the same pod pages someone again at four in the morning. If you must raise it to stop the bleeding, write down that you did and what the number was, because a limit raised under pressure and never revisited is how clusters end up paying for memory nothing uses. Requests and limits covers setting them deliberately.
Exit code 137 is not proof
137 means SIGKILL, and the out of memory killer is only one thing that sends it. Check that the reason field actually says OOMKilled before you start looking for memory. Reading exit codes 137 and 143 separates the cases.
What KubeGraf does with this one
KubeGraf correlates the kill with the container's memory against its limit, the node's pressure conditions and what deployed recently, so the limit case and the leak case separate themselves. Any change it proposes waits for approval.
The reference
The full causes, commands and fixes are on the reference page: OOMKilled.
Sources
Read on 25 November 2026. Check the source before you rely on a detail.
Frequently asked questions
Does exit code 137 always mean OOMKilled?
No. 137 means the process was killed with SIGKILL and the out of memory killer is only one thing that sends it. Check that the reason field says OOMKilled.
Should I just raise the memory limit?
Only once you know the workload needs it. A limit raised over a leak buys time and the pod dies again later, further into the night.
What is the difference between the container being killed and the node running out?
A container over its own limit is killed on its own. A node under memory pressure evicts pods instead, which shows as Evicted rather than OOMKilled.
How do I find a memory leak in a Kubernetes pod?
Look at the container's memory across several restarts rather than at one moment. A leak climbs steadily from each start until the limit, where a workload that is simply too big sits near the limit from the beginning.
Want this worked for you on your own clusters? Apply for KubeGraf Freemium. Three calendar months by approval, no card and no automatic paid conversion.
Last updated . Try KubeGraf Freemium.