Q: What are the three QoS classes in Kubernetes and how does each affect eviction?
1. Guaranteed — requests == limits for all containers. Both CPU and memory. Highest priority. Evicted last.
#Kubernetes #Advanced Scenarios #L3 #Container Orchestration #K8s
🎙️ Candidate Opening & Architectural Context
""In one of our high-traffic production clusters, our SRE team handled this incident using a standardized runbook. When addressing this question, I walk the interviewer through our production incident runbook: isolating the blast radius, checking diagnostic logs and metrics, and applying a safe fix.""
Advertisement
🛠️ Production Runbook & Step-by-Step Resolution
1️⃣
Initial Diagnostics & Root Cause Analysis
When a node runs out of memory, kubelet evicts pods in this order: BestEffort → Burstable (lowest priority score first) → Guaranteed.
- Guaranteed —
requests == limitsfor all containers. Both CPU and memory. Highest priority. Evicted last. - Burstable — at least one container has requests < limits, or not all containers have both set. Medium priority.
- BestEffort — no requests or limits set at all. Lowest priority. Evicted first when node is under memory pressure.
2️⃣
Remediation & Permanent Safeguards
For critical production workloads: use Guaranteed QoS (set requests = limits for memory at minimum) to protect them from eviction.
💡 The Senior SRE Gold Nugget (Key Architectural Takeaway)
"Pro-Tip: Guaranteed — requests == limits for all containers. Both CPU and memory. Highest priority. Evicted last.."
⚡ 60-Second Elevator Pitch Talking Points
- Guaranteed — requests == limits for all containers. Both CPU and memory. Highest priority. Evicte...
- Burstable — at least one container has requests < limits, or not all containers have both set. Me...
- BestEffort — no requests or limits set at all. Lowest priority. Evicted first when node is under ...
Advertisement