<p>As far as I can tell, if a Kubernetes pod fills an emptyDir volume that has a sizeLimit, the pod is immediately evicted, without following normal termination procedure.   (terminationGracePeriodSeconds, et cetera)</p>

<p>Is there a way to set a soft eviction threshold for an emptyDir volumes so that it does follow normal termination procedures?</p>

<p>If not, does anybody have a good suggestion on how to build an appropriate livenessProbe?   <code>df</code> shows disk free for the underlying disk, not the emptyDir, and <code>du</code> can be quite expensive.</p>

Bryan Larsen
<p>You can tweak your soft eviction thresholds for the kubelet</p>

<p>There are 3 parameters <code>eviction-soft</code>, <code>eviction-soft-grace-period</code>, and <code>eviction-max-pod-grace-period</code></p>

<p>More info <a href="https://kubernetes.io/docs/tasks/administer-cluster/out-of-resource/#soft-eviction-thresholds" rel="nofollow noreferrer">here</a></p>
