Insufficient replicas: single point of failure
Quick summary
Your service has only one replica — if it fails, the entire feature or application becomes unavailable.
Why this happens
The deployment is configured with replicas: 1 for cost savings
The service was deployed for development and not scaled for production
Auto-scaling is not configured and the initial replica count is 1
Minimal example
apiVersion: apps/v1
kind: Deployment
spec:
replicas: 1 # single point of failure
template:
spec:
containers:
- name: app
image: myapp:v1apiVersion: apps/v1
kind: Deployment
spec:
replicas: 3 # multiple replicas for HA
template:
spec:
containers:
- name: app
image: myapp:v1
---
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
spec:
scaleTargetRef:
kind: Deployment
name: app
minReplicas: 3
maxReplicas: 10Running 3 replicas and configuring auto-scaling ensures the service remains available even if one pod fails and can handle load spikes.
How to diagnose
Check the deployment replica count with kubectl get deployment or in the manifest
Review the application architecture for single points of failure
Verify that auto-scaling is configured if the load varies
How to fix
Increase the replica count to at least 2 for high availability
Configure horizontal pod auto-scaling based on CPU or custom metrics
Distribute replicas across multiple nodes or availability zones for fault tolerance
How to prevent
Always run at least 2 replicas in production for stateless services
Configure auto-scaling and spread replicas across availability zones for resilience
Related Resources
Related Glossary
Related Lessons
- High Availability
Learn about replicas.