A node drain for maintenance hangs with `Cannot evict pod as it would violate the pod's disruption budget.`
BeginnerTroubleshootingReliability Patterns in Production
Answer
Likely causes → A PodDisruptionBudget allows zero disruptions right now: minAvailable equals replica count, a single-replica deployment has minAvailable: 1, or some replicas are already unhealthy.
Diagnose →
kubectl get pdb -A
kubectl describe pdb -n shop checkout
Look at ALLOWED DISRUPTIONS.
Fix → Scale up so the PDB permits one disruption, fix unhealthy pods, or adjust the PDB (maxUnavailable: 1). Do not force-delete pods unless you accept the impact.
Prevent → At least 2 replicas for anything with a PDB, and use maxUnavailable rather than minAvailable equal to replicas.
More on Reliability Patterns in Production
Clients get 503s with body `upstream connect error or disconnect/reset before headers. reset reason: overflow`, and Envoy logs show flag `UO`.AdvancedNGINX ingress returns 504 and logs `upstream timed out (110: Connection timed out) while reading response header from upstream`.BeginnerAfter a 30-second database blip, Postgres keeps rejecting connections with `FATAL: sorry, too many clients already` for 20 minutes.AdvancedCustomers were charged twice during an incident where the payment API timed out.AdvancedEvery rolling deploy produces a short burst of 502s on the AWS ALB.IntermediateRedis restarted and immediately the database CPU hit 100% and the site went down.Advanced