<p>I try to get a general understanding of OOMKilled events and I've found 2 different reasons:</p>
<ol>
<li><p><strong>Pod</strong> memory limit exceeded: <a href="https://kubernetes.io/docs/tasks/configure-pod-container/assign-memory-resource/#exceed-a-container-s-memory-limit" rel="noreferrer">If the Container continues to consume memory beyond its limit, the Container is terminated.</a></p>
</li>
<li><p><strong>Node</strong> out of memory: <a href="https://kubernetes.io/docs/tasks/administer-cluster/out-of-resource/#node-oom-behavior" rel="noreferrer">If the kubelet is unable to reclaim memory prior to a node experiencing system OOM, ... then kills the container ...</a></p>
</li>
</ol>
<p><strong>Questions</strong></p>
<ul>
<li>Is this correct?</li>
<li>Are there any other reasons?</li>
<li>Is it possible to see which reason caused the OOMKilled? (It's important to know the reason, because the remedy will be different.)</li>
</ul>

<p>Both problems result in different error states:</p>
<p>1: An exceeded pod memory limit causes a <code>OOMKilled</code> termination</p>
<p>2: Node out of memory causes a <code>MemoryPressure</code> and and pod eviction.</p>
<pre><code>kubectl describe pod mypod-xxxx

...
Reason:         Evicted
Message:        Pod The node had condition: [MemoryPressure].
...
</code></pre>
