Surge Upgrade IP Exhaustion¶
Symptom¶
The upgrade fails while trying to create surge nodes, often with subnet-capacity errors or stalled node-pool rollout. This applies to networking models that consume subnet IPs per pod (Azure CNI with a pod subnet); Azure CNI Overlay and other non-subnet pod-IP models do not consume node-subnet IPs per pod and use different headroom math.
Possible Causes¶
- The subnet has insufficient IP headroom for the planned surge.
maxSurgeis too high for the current subnet size.maxPodsand node density assumptions left no upgrade buffer.- Orphaned or unused network allocations were never reclaimed.
Diagnosis Steps¶
flowchart TD
A[Surge nodes fail to provision] --> B[Read subnet and node pool settings]
B --> C[Calculate required IP headroom]
C --> D{Enough IPs available?}
D -->|No| E[Lower surge or expand subnet]
D -->|Yes| F[Inspect other capacity blockers] -
Read cluster networking and node-pool assumptions.
az aks show \ --resource-group "$RG" \ --name "$CLUSTER_NAME" \ --query "networkProfile" \ --output yamlCommand Purpose az aks showShow the cluster network profile. --resource-groupResource group that contains the AKS cluster. --nameName of the AKS cluster. --querySelects the network profile. --outputOutput format for the result. -
Review the backing subnet.
az network vnet subnet show \ --resource-group "$VNET_RG" \ --vnet-name "$VNET_NAME" \ --name "$AKS_SUBNET_NAME" \ --output yamlCommand Purpose az network vnet subnet showShow the AKS subnet configuration. --resource-groupResource group that contains the virtual network. --vnet-nameName of the virtual network. --nameName of the AKS subnet. --outputOutput format for the result. -
For Azure CNI with a pod subnet, calculate whether the subnet can satisfy
(nodes + maxSurge) * (1 + maxPods). (Azure CNI Overlay allocates pod IPs from a separate CIDR, so size the node subnet for nodes plus surge only.)
Resolution¶
- Lower
maxSurgeif the current subnet cannot absorb the planned temporary growth. - Expand the subnet or redesign IP allocation before retrying.
- Reclaim stale or unused allocations if that is part of the pressure.
Prevention¶
- Reserve IP headroom for both autoscaler growth and upgrade surge.
- Document subnet math in the production blueprint, not only in the incident review.
- Review surge assumptions whenever node count or
maxPodschanges materially.