Manually scale nodes in an Azure Kubernetes Service (AKS) cluster - Azure Kubernetes Service (2024)

  • Article

If the resource needs of your applications change, your cluster performance may be impacted due to low capacity on CPU, memory, PID space, or disk sizes. To address these changes, you can manually scale your AKS cluster to run a different number of nodes. When you scale down, nodes are carefully cordoned and drained to minimize disruption to running applications. When you scale up, AKS waits until nodes are marked Ready by the Kubernetes cluster before pods are scheduled on them.

This article describes how to manually increase or decrease the number of nodes in an AKS cluster.

Before you begin

Scale the cluster nodes

Important

Removing nodes from a node pool using the kubectl command isn't supported. Doing so can create scaling issues with your AKS cluster.

  • Azure CLI
  • Azure PowerShell
  1. Get the name of your node pool using the az aks show command. The following example gets the node pool name for the cluster named myAKSCluster in the myResourceGroup resource group:

    az aks show --resource-group myResourceGroup --name myAKSCluster --query agentPoolProfiles

    The following example output shows that the name is nodepool1:

    [ { "count": 1, "maxPods": 110, "name": "nodepool1", "osDiskSizeGb": 30, "osType": "Linux", "vmSize": "Standard_DS2_v2" }]
  2. Scale the cluster nodes using the az aks scale command. The following example scales a cluster named myAKSCluster to a single node. Provide your own --nodepool-name from the previous command, such as nodepool1:

    az aks scale --resource-group myResourceGroup --name myAKSCluster --node-count 1 --nodepool-name <your node pool name>

    The following example output shows the cluster successfully scaled to one node, as shown in the agentPoolProfiles section:

    { "aadProfile": null, "addonProfiles": null, "agentPoolProfiles": [ { "count": 1, "maxPods": 110, "name": "nodepool1", "osDiskSizeGb": 30, "osType": "Linux", "vmSize": "Standard_DS2_v2", "vnetSubnetId": null } ], [...]}

Scale User node pools to 0

Unlike System node pools that always require running nodes, User node pools allow you to scale to 0. To learn more on the differences between system and user node pools, see System and user node pools.

Important

You can't scale a user node pool with the cluster autoscaler enabled to 0 nodes. To scale a user node pool to 0 nodes, you must disable the cluster autoscaler first. For more information, see Disable the cluster autoscaler on a node pool.

  • Azure CLI
  • Azure PowerShell
  • To scale a user pool to 0, you can use the az aks nodepool scale in alternative to the above az aks scale command, and set 0 as your node count.

    az aks nodepool scale --name <your node pool name> --cluster-name myAKSCluster --resource-group myResourceGroup --node-count 0 
  • You can also autoscale User node pools to zero nodes, by setting the --min-count parameter of the Cluster Autoscaler to 0.

Next steps

In this article, you manually scaled an AKS cluster to increase or decrease the number of nodes. You can also use the cluster autoscaler to automatically scale your cluster.

Manually scale nodes in an Azure Kubernetes Service (AKS) cluster - Azure Kubernetes Service (2024)
Top Articles
What is NFC & how to use it with your phone to make contactless payments | Samsung UK
Reese Witherspoon's Makeup Artist Applied This $15 Serum
What Did Bimbo Airhead Reply When Asked
UPS Paketshop: Filialen & Standorte
Amc Near My Location
Craigslist Vans
Kaydengodly
Bucks County Job Requisitions
Pitt Authorized User
<i>1883</i>'s Isabel May Opens Up About the <i>Yellowstone</i> Prequel
Premier Boating Center Conroe
Sport Clip Hours
Diablo 3 Metascore
2016 Ford Fusion Belt Diagram
Mineral Wells Independent School District
Colorado mayor, police respond to Trump's claims that Venezuelan gang is 'taking over'
What Happened To Anna Citron Lansky
Locate At&T Store Near Me
Niche Crime Rate
Wgu Academy Phone Number
Project, Time & Expense Tracking Software for Business
Www.publicsurplus.com Motor Pool
Craigslist Battle Ground Washington
Valic Eremit
Hctc Speed Test
Arrest Gif
Jesus Revolution Showtimes Near Regal Stonecrest
Speedstepper
Free T33N Leaks
2004 Honda Odyssey Firing Order
Frank Vascellaro
Korg Forums :: View topic
Robot or human?
Does Iherb Accept Ebt
Western Gold Gateway
Vanessa West Tripod Jeffrey Dahmer
Bimmerpost version for Porsche forum?
How To Get Soul Reaper Knife In Critical Legends
Wsbtv Fish And Game Report
NHL training camps open with Swayman's status with the Bruins among the many questions
Dr Adj Redist Cadv Prin Amex Charge
Anhedönia Last Name Origin
Gasoline Prices At Sam's Club
Promo Code Blackout Bingo 2023
Shell Gas Stations Prices
Rs3 Nature Spirit Quick Guide
4k Movie, Streaming, Blu-Ray Disc, and Home Theater Product Reviews & News
Matt Brickman Wikipedia
Taterz Salad
Affidea ExpressCare - Affidea Ireland
Ravenna Greataxe
Latest Posts
Article information

Author: Arline Emard IV

Last Updated:

Views: 6583

Rating: 4.1 / 5 (52 voted)

Reviews: 83% of readers found this page helpful

Author information

Name: Arline Emard IV

Birthday: 1996-07-10

Address: 8912 Hintz Shore, West Louie, AZ 69363-0747

Phone: +13454700762376

Job: Administration Technician

Hobby: Paintball, Horseback riding, Cycling, Running, Macrame, Playing musical instruments, Soapmaking

Introduction: My name is Arline Emard IV, I am a cheerful, gorgeous, colorful, joyous, excited, super, inquisitive person who loves writing and wants to share my knowledge and understanding with you.