Practical guide

How to Right-Size Kubernetes Ephemeral Storage

A practical method for sizing ephemeral-storage requests and limits from logs, writable layers, emptyDir data, and eviction headroom.

Updated · Sources checked

Right-sizing ephemeral storage starts with measurement, not a generic per-pod number. Record peak writable-layer, log, and emptyDir usage for a representative workload window, then add explicit headroom for deploys, retries, and log bursts.

Requests and limits are different

The request influences scheduling; the limit caps the pod’s configured ephemeral-storage usage. Set the request near a measured peak plus operational headroom, and set the limit high enough to avoid normal bursts without allowing unbounded disk growth.

Use the ephemeral storage calculator to aggregate those per-pod values across replicas. Then compare the total with node allocatable storage and disk-pressure eviction thresholds. The pod capacity calculator can help with CPU and memory, but it does not model disk pressure.

Three checks before production

  1. Confirm logs have rotation and retention limits.
  2. Give temporary files and emptyDir data an explicit size limit where appropriate.
  3. Load-test a rollout and failure retry, because those events often create the largest short-lived disk spike.

Official sources

Related calculators

Continue reading