You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
> Message="**Allocation failed. We do not have sufficient capacity for the requested VM size in this zone.** Read more about improving likelihood of allocation success at <https://aka.ms/allocation-guidance>";
37
-
>
38
-
> AKSTeam: NodeProvisioning
26
+
Code: `ZonalAllocationFailed`
39
27
40
-
Or, when you try to upgrade or scale up a cluster, you receive the following error message:
28
+
Message: "Allocation failed. We do not have sufficient capacity for the requested VM size in this zone. Read more about improving likelihood of allocation success at https://aka.ms/allocation-guidance. Please note that allocation failures can also arise if a proximity placement group is associated with this VMSS. See https://learn.microsoft.com/troubleshoot/azure/azure-kubernetes/error-code-zonalallocationfailed-allocationfailed for more details. This is not AKS controlled behavior, please ask help to VMSS team for allocation failure. If the error is due to capacity constrain, consider upgrade with maxUnavailable instead of maxSurge, details: aka.ms/aks/maxUnavailable."
41
29
42
-
> Code="OverconstrainedAllocationRequest"
43
-
>
44
-
> Message="**Allocation failed. VM(s) with the following constraints cannot be allocated, because the condition is too restrictive.** Please remove some constraints and try again."
30
+
Code: `AllocationFailed`
45
31
46
-
Or, when you use dedicated hosts in a cluster and try to create or scale up a node pool, you receive the following error message:
32
+
Message: "The VM allocation failed due to an internal error. Please retry later or try deploying to a different location. Please note that allocation failures can also arise if a proximity placement group is associated with this VMSS. See https://learn.microsoft.com/troubleshoot/azure/azure-kubernetes/error-code-zonalallocationfailed-allocationfailed for more details.This is not AKS controlled behavior, please ask help to VMSS team for allocation failure."
47
33
48
-
> Code="AllocationFailed"
49
-
>
50
-
> Message="**Allocation failed. VM allocation to the dedicated host failed. Please ensure that the dedicated host has enough capacity or try allocating elsewhere.**"
34
+
Code: `OverconstrainedAllocationRequest`
51
35
52
-
## Cause 1: Limited zone availability in a SKU
36
+
Message: "Create or update VMSS failed. Allocation failed. VM(s) with the following constraints cannot be allocated, because the condition is too restrictive. Please remove some constraints and try again. Constraints applied are: - Differencing (Ephemeral) Disks - Networking Constraints (such as Accelerated Networking or IPv6) - VM Size"
37
+
38
+
### Cause 1: Limited zone availability in a SKU
53
39
54
40
You're trying to deploy, upgrade or scale up a cluster in a zone that has limited availability for the specific SKU.
55
41
56
-
## Solution 1: Use a different SKU, zone, or region
42
+
###Solution 1: Use a different SKU, zone, or region
57
43
58
44
Try one or more of the following methods:
59
45
@@ -64,6 +50,28 @@ Try one or more of the following methods:
64
50
65
51
For more information about how to fix this error, see [Resolve errors for SKU not available](/azure/azure-resource-manager/troubleshooting/error-sku-not-available).
66
52
53
+
### Solution 2: Dynamically scale using Node Auto Provisioning
54
+
55
+
[Node Auto Provisioning](/azure/aks/node-auto-provisioning) allows you to automatically provision VM SKUs based on your workload needs. If a SKU isn't available due to capacity constraints, Node Auto Provisioning (NAP) selects another SKU type based on the specifications provided in the customer resource definitions (CRDs) like `NodePool` and `AKSNodeClass`. This can be helpful for scaling scenarios when certain SKU capacity becomes limited. For more information on configuring your NAP cluster, see [Configure node pools for node auto-provisioning (NAP) in Azure Kubernetes Service (AKS)](/azure/aks/node-auto-provisioning-node-pools) and [Configure AKSNodeClass resources for node auto-provisioning (NAP) in Azure Kubernetes Service (AKS)](https://learn.microsoft.com/azure/aks/node-auto-provisioning-aksnodeclass).
56
+
57
+
### Solution 3: Upgrade in place using `MaxUnavailable`
58
+
59
+
If you don’t need surge nodes during upgrades, see [Customize unavailable nodes](/azure/aks/upgrade-aks-node-pools-rolling#customize-unavailable-nodes) for information on how to upgrade with the existing capacity. Set `MaxUnavailable` to a value greater than 0 and set `MaxSurge` equal to 0. Existing nodes are then cordoned and drained one at a time and pods are evicted to remaining nodes. No buffer node is created.
60
+
61
+
### Solution 4: Use deployment recommender in portal for new cluster creates
62
+
63
+
During an AKS cluster creation in the Azure portal, if the selected nodepool SKU isn't available in the chosen region and zones, the deployment recommender recommends an alternative SKU, zones, and region combination that has availability.
64
+
65
+
## Solution 5: Use priority expanders with cluster-autoscaler
66
+
67
+
The cluster-autoscaler [priority expander](https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/expander/priority/readme.md) lets you define an ordered list of node pools to attempt scaling in sequence. For example: Spot pools first (cost optimization), then on-demand pools (availability fallback). Conditional Access tries to implement the highest priority pool first. If scaling fails (for example, due to allocation failure), it tries the next pool.
68
+
69
+
**Limitations**
70
+
71
+
- Conditional Access doesn't create new node pools. It only works with existing pools. If you want dynamic SKU provisioning, use NAP, which can create pools based on SKU availability.
72
+
73
+
- Priority expander works at node pool level, not SKU level. You must pre-create pools for each SKU family you want to use.
74
+
67
75
## Cause 2: Too many constraints for a virtual machine to accommodate
68
76
69
77
If you receive an `OverconstrainedAllocationRequest` error code, the Azure Compute platform can't allocate a new virtual machine (VM) to accommodate the required constraints. These constraints usually (but not always) include the following items:
@@ -75,15 +83,15 @@ If you receive an `OverconstrainedAllocationRequest` error code, the Azure Compu
75
83
- Ephemeral disk
76
84
- Proximity placement group (PPG)
77
85
78
-
## Solution 2: Don't associate a proximity placement group with the node pool
86
+
## Solution: Don't associate a proximity placement group with the node pool
79
87
80
88
If you receive an `OverconstrainedAllocationRequest` error code, you can try to create a new node pool that isn't associated with a proximity placement group.
81
89
82
90
## Cause 3: Not enough dedicated hosts or fault domains
83
91
84
92
You're trying to deploy a node pool in a dedicated host group that has limited capacity or doesn't satisfy the fault domain constraint.
85
93
86
-
## Solution 3: Ensure you have enough dedicated hosts for your AKS nodes/VMSS
94
+
## Solution: Ensure you have enough dedicated hosts for your AKS nodes/VMSS
87
95
88
96
As per [Planning for ADH Capacity on AKS](/azure/aks/use-azure-dedicated-hosts#planning-for-adh-capacity-on-aks), you're responsible for planning enough dedicated hosts to span as many fault domains as required by your AKS VMSS. For example, if the AKS VMSS is created with *FaultDomainCount=2*, you need at least two dedicated hosts in different fault domains (*FaultDomain 0* and *FaultDomain 1*).
89
97
@@ -101,4 +109,3 @@ We have identified several methods to improve how we load-balance under a high-r
101
109
102
110
-[Fix an AllocationFailed or ZonalAllocationFailed error when you create, restart, or resize Virtual Machine Scale Sets in Azure](../../virtual-machine-scale-sets/allocationfailed-or-zonalallocationfailed.md)
103
111
104
-
[!INCLUDE [Azure Help Support](../../../includes/azure-help-support.md)]
0 commit comments