Skip to content

Commit 196251b

Browse files
committed
Resolving build report warnings
1 parent 66c9a91 commit 196251b

File tree

2 files changed

+40
-40
lines changed

2 files changed

+40
-40
lines changed

articles/aks/configure-azure-cni-dynamic-ip-allocation.md

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,17 @@ ms.date: 01/09/2023
77
ms.custom: references_regions, devx-track-azurecli
88
---
99

10-
## Configure Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in Azure Kubernetes Service (AKS)
10+
# Configure Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in Azure Kubernetes Service (AKS)
1111

1212
A drawback with the traditional CNI is the exhaustion of pod IP addresses as the AKS cluster grows, which results in the need to rebuild your entire cluster in a bigger subnet. The new dynamic IP allocation capability in Azure CNI solves this problem by allocating pod IPs from a subnet separate from the subnet hosting the AKS cluster.
1313

1414
It offers the following benefits:
1515

16-
* **Better IP utilization**: IPs are dynamically allocated to cluster Pods from the Pod subnet. This leads to better utilization of IPs in the cluster compared to the traditional CNI solution, which does static allocation of IPs for every node.
17-
* **Scalable and flexible**: Node and pod subnets can be scaled independently. A single pod subnet can be shared across multiple node pools of a cluster or across multiple AKS clusters deployed in the same VNet. You can also configure a separate pod subnet for a node pool.
18-
* **High performance**: Since pod are assigned VNet IPs, they have direct connectivity to other cluster pod and resources in the VNet. The solution supports very large clusters without any degradation in performance.
19-
* **Separate VNet policies for pods**: Since pods have a separate subnet, you can configure separate VNet policies for them that are different from node policies. This enables many useful scenarios such as allowing internet connectivity only for pods and not for nodes, fixing the source IP for pod in a node pool using a VNet Network NAT, and using NSGs to filter traffic between node pools.
20-
* **Kubernetes network policies**: Both the Azure Network Policies and Calico work with this new solution.
16+
* **Better IP utilization**: IPs are dynamically allocated to cluster Pods from the Pod subnet. This leads to better utilization of IPs in the cluster compared to the traditional CNI solution, which does static allocation of IPs for every node.
17+
* **Scalable and flexible**: Node and pod subnets can be scaled independently. A single pod subnet can be shared across multiple node pools of a cluster or across multiple AKS clusters deployed in the same VNet. You can also configure a separate pod subnet for a node pool.
18+
* **High performance**: Since pod are assigned VNet IPs, they have direct connectivity to other cluster pod and resources in the VNet. The solution supports very large clusters without any degradation in performance.
19+
* **Separate VNet policies for pods**: Since pods have a separate subnet, you can configure separate VNet policies for them that are different from node policies. This enables many useful scenarios such as allowing internet connectivity only for pods and not for nodes, fixing the source IP for pod in a node pool using a VNet Network NAT, and using NSGs to filter traffic between node pools.
20+
* **Kubernetes network policies**: Both the Azure Network Policies and Calico work with this new solution.
2121

2222
This article shows you how to use Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in AKS.
2323

@@ -64,49 +64,49 @@ Using dynamic allocation of IPs and enhanced subnet support in your cluster is s
6464

6565
Create the virtual network with two subnets.
6666

67-
```azurecli-interactive
68-
resourceGroup="myResourceGroup"
69-
vnet="myVirtualNetwork"
70-
location="westcentralus"
67+
```azurecli-interactive
68+
resourceGroup="myResourceGroup"
69+
vnet="myVirtualNetwork"
70+
location="westcentralus"
7171
72-
# Create the resource group
73-
az group create --name $resourceGroup --location $location
72+
# Create the resource group
73+
az group create --name $resourceGroup --location $location
7474
75-
# Create our two subnet network
76-
az network vnet create -g $resourceGroup --location $location --name $vnet --address-prefixes 10.0.0.0/8 -o none
77-
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name nodesubnet --address-prefixes 10.240.0.0/16 -o none
78-
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name podsubnet --address-prefixes 10.241.0.0/16 -o none
79-
```
75+
# Create our two subnet network
76+
az network vnet create -g $resourceGroup --location $location --name $vnet --address-prefixes 10.0.0.0/8 -o none
77+
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name nodesubnet --address-prefixes 10.240.0.0/16 -o none
78+
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name podsubnet --address-prefixes 10.241.0.0/16 -o none
79+
```
8080

8181
Create the cluster, referencing the node subnet using `--vnet-subnet-id` and the pod subnet using `--pod-subnet-id`.
8282

83-
```azurecli-interactive
84-
clusterName="myAKSCluster"
85-
subscription="aaaaaaa-aaaaa-aaaaaa-aaaa"
83+
```azurecli-interactive
84+
clusterName="myAKSCluster"
85+
subscription="aaaaaaa-aaaaa-aaaaaa-aaaa"
8686
87-
az aks create -n $clusterName -g $resourceGroup -l $location \
88-
--max-pods 250 \
89-
--node-count 2 \
90-
--network-plugin azure \
91-
--vnet-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/nodesubnet \
92-
--pod-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/podsubnet
93-
```
87+
az aks create -n $clusterName -g $resourceGroup -l $location \
88+
--max-pods 250 \
89+
--node-count 2 \
90+
--network-plugin azure \
91+
--vnet-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/nodesubnet \
92+
--pod-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/podsubnet
93+
```
9494

9595
### Adding node pool
9696

9797
When adding node pool, reference the node subnet using `--vnet-subnet-id` and the pod subnet using `--pod-subnet-id`. The following example creates two new subnets that are then referenced in the creation of a new node pool:
9898

99-
```azurecli-interactive
100-
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name node2subnet --address-prefixes 10.242.0.0/16 -o none
101-
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name pod2subnet --address-prefixes 10.243.0.0/16 -o none
102-
103-
az aks nodepool add --cluster-name $clusterName -g $resourceGroup -n newnodepool \
104-
--max-pods 250 \
105-
--node-count 2 \
106-
--vnet-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/node2subnet \
107-
--pod-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/pod2subnet \
108-
--no-wait
109-
```
99+
```azurecli-interactive
100+
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name node2subnet --address-prefixes 10.242.0.0/16 -o none
101+
az network vnet subnet create -g $resourceGroup --vnet-name $vnet --name pod2subnet --address-prefixes 10.243.0.0/16 -o none
102+
103+
az aks nodepool add --cluster-name $clusterName -g $resourceGroup -n newnodepool \
104+
--max-pods 250 \
105+
--node-count 2 \
106+
--vnet-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/node2subnet \
107+
--pod-subnet-id /subscriptions/$subscription/resourceGroups/$resourceGroup/providers/Microsoft.Network/virtualNetworks/$vnet/subnets/pod2subnet \
108+
--no-wait
109+
```
110110

111111
## Dynamic allocation of IP addresses and enhanced subnet support FAQs
112112

articles/aks/operator-best-practices-run-at-scale.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ To increase the node limit beyond 1000, you must have the following pre-requisit
3131
## Networking considerations and best practices
3232

3333
* Use Managed NAT for cluster egress with at least 2 public IPs on the NAT Gateway. For more information, see [Managed NAT Gateway with AKS][Managed NAT Gateway - Azure Kubernetes Service].
34-
* Use Azure CNI with Dynamic IP allocation for optimum IP utilization, and scale up to 50k application pods per cluster with one routable IP per pod. For more information, see [Configure Azure CNI networking in AKS][Configure Azure CNI networking in Azure Kubernetes Service (AKS)].
34+
* Use Azure CNI with Dynamic IP allocation for optimum IP utilization, and scale up to 50k application pods per cluster with one routable IP per pod. For more information, see [Configure Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in AKS][Configure Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in Azure Kubernetes Service (AKS)].
3535
* When using internal Kubernetes services behind an internal load balancer, we recommend creating an internal load balancer or internal service below 750 node scale for optimal scaling performance and load balancer elasticity.
3636

3737
> [!NOTE]
@@ -56,7 +56,7 @@ To increase the node limit beyond 1000, you must have the following pre-requisit
5656

5757
<!-- Links - External -->
5858
[Managed NAT Gateway - Azure Kubernetes Service]: nat-gateway.md
59-
[Configure Azure CNI networking in Azure Kubernetes Service (AKS)]: configure-azure-cni.md#dynamic-allocation-of-ips-and-enhanced-subnet-support
59+
[Configure Azure CNI networking for dynamic allocation of IPs and enhanced subnet support in Azure Kubernetes Service (AKS)]: configure-azure-cni-dynamic-ip-allocation.md
6060
[max surge]: upgrade-cluster.md?tabs=azure-cli#customize-node-surge-upgrade
6161
[Azure portal]: https://portal.azure.com/#create/Microsoft.Support/Parameters/%7B%0D%0A%09%22subId%22%3A+%22%22%2C%0D%0A%09%22pesId%22%3A+%225a3a423f-8667-9095-1770-0a554a934512%22%2C%0D%0A%09%22supportTopicId%22%3A+%2280ea0df7-5108-8e37-2b0e-9737517f0b96%22%2C%0D%0A%09%22contextInfo%22%3A+%22AksLabelDeprecationMarch22%22%2C%0D%0A%09%22caller%22%3A+%22Microsoft_Azure_ContainerService+%2B+AksLabelDeprecationMarch22%22%2C%0D%0A%09%22severity%22%3A+%223%22%0D%0A%7D
6262
[uptime SLA]: uptime-sla.md

0 commit comments

Comments
 (0)