# How to Create an AKS Cluster with Kubenet > [!NOTE] > **WHAT TO EXPECT** > > In this section, users will learn how to deploy an AKS Cluster with Kubenet as the default network plugin. ## Creating an AKS Cluster > [!WARNING] > **cloudSwXtch VM Minimum Requirements** > > Before you start, ensure that your cloudSwXtch has met the following minimum requirements: > > - Must have at least 4, preferably 8 cores. > - Must have at least 2 NICs. Both NICs must share a single subnet. The 2nd one must support accelerated networking. > - Must run one of the operating systems listed in [cloudSwXtch System Requirements](../../../../cloudswxtch/installing-cloudswxtch/cloudswxtch-system-requirements.md#operating-system-and-kernel). > > A cloudSwXtch must be created before you install the xNIC on the AKS Cluster. For more information on Azure cloudSwXtch installation, see: [cloudSwXtch on Azure](../../../../cloudswxtch/installing-cloudswxtch/cloudswxtch-on-azure/index.md) Users will need two items in order to create the AKS Cluster with Kubenet: **AZ CLI** and **kubectl**. **AZ CLI** comes installed on Azure Cloudshell, while kubectl can be either installed on your active Cloudshell session, or on any VM that you want to use for managing the K8s cluster. Prior to running the script, ensure the following are already created in Azure: - **Azure Resource Group** (must be the same as the one used to create the cloudSwXtch) - **Azure VNET** (must be the same as the one used to create the cloudSwXtch) - **Azure Control Subnet** (must be the same as the one used to create the cloudSwXtch) Each of the components **must match** the one used to create the cloudSwXtch on Azure. The cluster nodes must be able to reach the cloudSwXtch control IP on **TCP 9443** (control) and **TCP 443** (the cloudSwXtch's xNIC image registry). ### AKS with Kubenet CNI Creation 1. Log into the Azure Portal. 2. Open **cloudshell** as bash. ![k8s-AKS-cloudshell-bash](../../../../assets/document360/422146bd65-k8s-aks-cloudshell-bash.png) 3. Run the following command to download the **kubectl** binary: ``` curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" ``` 4. Install **AZ CLI** by following instructions in the  link: 5. Run the following script replacing the following: - ****: User-assigned name for AKS Cluster - ****: Azure Resource Group - ****: Azure VNET - ****: Azure CONTROL Subnet **This is to install a simple 2-node AKS with Kubenet CNI.** ``` export NAME="" export AZURE_RESOURCE_GROUP="" # Get the Subnet id export SUBNET_ID="$(az network vnet subnet show -g ${AZURE_RESOURCE_GROUP} -n --vnet-name --query id --output tsv)" # Create AKS cluster az aks create \ --generate-ssh-keys \ --resource-group "${AZURE_RESOURCE_GROUP}" \ --name "${NAME}" \ --vnet-subnet-id "${SUBNET_ID}" \ --node-vm-size Standard_Ds2_v2 \ --node-count 2 # Get the credentials to access the cluster with kubectl az aks get-credentials --resource-group "${AZURE_RESOURCE_GROUP}" --name "${NAME}" ``` After executing the script with the replaced values, the AKS Cluster will be created. Users will get the following line as confirmation. ``` Merged "sample-kubenet" as current context in /.kube/config ``` **Note**: The user in this example used the name "**sample-kubenet**" for their . You may choose whatever you want to name your AKS Cluster 6. Confirm the cluster is **available** and **reachable** by running the following command: ``` $ kubectl config get-contexts ``` ### Example Response ``` $ kubectl config get-contexts CURRENT NAME CLUSTER AUTHINFO NAMESPACE * sample-kubenet sample-kubenet clusterUser_swxtch-bosch_sample-kubenet $ ``` > [!NOTE] > **Installing xNIC in Kubernetes Cluster** > > After creating an AKS Cluster with Kubenet CNI, continue on to Installing xNIC on Kubernetes Cluster for instructions on how to deploy an xNIC.