Back to all scenarios
Scenario #494
Scaling & Load
Kubernetes v1.21, Google Kubernetes Engine (GKE)
Inconsistent Pod Distribution Across Node Pools
Pods were not evenly distributed across node pools after scaling, leading to uneven resource utilization.
Find this helpful?
What Happened
After scaling up the pod replicas, some node pools became overloaded while others had little load, causing inefficient resource utilization and application performance degradation.
Diagnosis Steps
- 1Checked pod affinity and anti-affinity rules to ensure there was no misconfiguration.
- 2Used kubectl describe to review pod scheduling and found that the scheduler preferred nodes from a specific pool despite resource availability in others.
Root Cause
Misconfigured pod affinity/anti-affinity rules and insufficient diversification in the node pool setup.
Fix/Workaround
• Reconfigured pod affinity and anti-affinity rules to ensure even distribution across node pools.
• Adjusted node pool configurations to ensure they could handle workloads more evenly.
Lessons Learned
Pod distribution across node pools should be optimized to ensure balanced resource usage.
How to Avoid
- 1Use node affinity and anti-affinity rules to better control how pods are scheduled across different node pools.
- 2Regularly monitor pod distribution to ensure load balancing across nodes.