A drain hangs forever on `Cannot evict pod as it would violate the pod's disruption budget`. What now?
AdvancedScenarioResources, autoscaling and scheduling
Answer
Situation read → A PDB with minAvailable equal to replicas blocks every eviction.
What I'd do →
kubectl get pdb -Aand check ALLOWED DISRUPTIONS equals 0- Check the workload has too few replicas or unhealthy pods
- Fix the PDB (use
maxUnavailable: 1) or scale up first - Never force-delete as a habit
- As a last resort use
--disable-evictionknowing it bypasses PDBs
Why → A PDB that allows zero disruptions makes the workload undrainable.
Interview tip → Say PDBs need to be reviewed in platform onboarding.
More on Resources, autoscaling and scheduling
How do you choose requests and limits for a new service?BeginnerPods are Pending with `0/6 nodes are available: 6 Insufficient cpu`. What do you do?IntermediateExplain QoS classes and which pods get evicted first.IntermediateCPU limits cause latency spikes though average usage is low. Why and what is the fix?IntermediateHow do you configure an HPA on CPU?BeginnerHPA shows `<unknown>/70%` for CPU. What do you do?Intermediate