Pods are being evicted with "The node was low on resource: ephemeral-storage. Container app was using 18Gi, which exceeds its request of 0."

IntermediateTroubleshootingDisk, memory and CPU
Answer

Likely causes → Containers write lots of data to their writable layer or emptyDir: logs written to files inside the container, temp files from uploads or image processing, or a cache. When the node's root disk crosses the kubelet eviction threshold (nodefs.available<10% by default), kubelet evicts the biggest users.

Diagnose →

kubectl get events -A --field-selector reason=Evicted
kubectl describe node <node> | grep -A5 Conditions
kubectl debug node/<node> -it --image=busybox -- du -sh /host/var/lib/containerd /host/var/log/pods

Fix → Log to stdout instead of files, move scratch data to an emptyDir with sizeLimit, and set ephemeral-storage requests and limits:

resources:
  requests: { ephemeral-storage: "2Gi" }
  limits:   { ephemeral-storage: "4Gi" }

Prevent → Larger node root volumes, ephemeral-storage limits in your default LimitRange, and alerts on node DiskPressure.

All Real-World Interview questions Roadmap: Interview readiness

More on Disk, memory and CPU