Q: What are the different types of probes, and which probe acts first — Startup, Readiness, or Liveness?
Detailed breakdown of the Kubernetes health probe evaluation lifecycle, explaining why startupProbe runs first and how readiness and liveness interact to prevent deployment death spirals.
Want to master this scenario in a live sandbox? KodeKloud's CKA & CKAD Hands-On Certification Track covers this exact problem with hands-on terminal drills.
🛠️ Production Runbook & Step-by-Step Resolution
Direct Answer: Kubernetes provides three distinct health probes: Startup, Readiness, and Liveness. The Startup probe ALWAYS acts first. Until the Startup probe succeeds, both Liveness and Readiness probes are completely disabled.
The Execution Hierarchy (Startup Probe Acts First)
On container launch, the kubelet runs the startupProbe. While it runs, liveness and readiness probes do not execute. If the startup probe fails to succeed within initialDelaySeconds + (periodSeconds * failureThreshold), the container is killed and restarted.
Readiness Probe: Controls Traffic Routing
Once startup passes, the readinessProbe executes periodically. If it fails, the container is NOT restarted. Instead, the kubelet removes the Pod IP from the Service EndpointSlice so it stops receiving user traffic.
Liveness Probe: Controls Container Lifecycle (Self-Healing)
The livenessProbe detects deadlocks where the process is running but cannot make progress. If it fails, the kubelet kills the container and invokes the restartPolicy.
- StartupProbe acts first: all readiness and liveness checks are disabled until it succeeds.
- ReadinessProbe controls routing: failure strips the pod IP from Endpoints without restarting the container.
- LivenessProbe controls restarts: failure triggers container termination (SIGTERM/SIGKILL) for deadlocks.
- Use startupProbe with high failureThreshold for legacy apps instead of huge initialDelaySeconds.
Senior hiring managers and bar raisers evaluate how you prioritize during outages. Avoid these common anti-patterns:
- Over-granting cluster-admin permissions to pod ServiceAccounts instead of scoping namespace Roles when configuring Kubernetes Health Probe Over-granting cluster-wide permissions violates least-privilege principles and allows compromised pods to escalate privileges across namespaces.
-
Referencing mutable latest container tags across production Kubernetes Deployment specs when configuring Kubernetes Health Probe
Deployments referencing
:latestrisk inconsistent versions across replica pods and break deterministic rollback capabilities. - Omitting pod readiness probes, causing traffic to hit uninitialized application containers when configuring Kubernetes Health Probe Readiness probes gate traffic delivery; missing probes cause Kubernetes to route user requests to pods before dependencies or caches are loaded.
- Executing diagnostic triage without analyzing chronological cluster events and describe outputs when configuring Kubernetes Health Probe Cluster events provide sequential timestamps of scheduler decisions, probe failures, and image pull timeouts essential for rapid root-cause isolation.