Azure-docs: difference between Kubectl autoscale and az aks autoascale.

Created on 15 Dec 2019  Â·  4Comments  Â·  Source: MicrosoftDocs/azure-docs

What is the difference between kubectl autoscale and az aks autoscale?


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri1 container-servicsvc cxp product-question triaged

All 4 comments

@jeanpoelie
Thanks for your feedback! We will investigate and update as appropriate.

@jeanpoelie Kubectl acts on the pods. az aks scale acts on nodes. i hope you are mentioning az aks scale only instead of az aks autoscale

Example for kubectl:
For example we can automatically increase the number of pods in a deployment based on certain condition. That condition is called as the autoscaling policy.

Lets take a lokk at the below command
kubectl autoscale rc foo --max=5 --cpu-percent=80
This scales the foo replication controller when cpu percent of pods crosses 80

Reference: https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#autoscale

example for az aks autoscale
az aks scale --resource-group myResourceGroup --name myAKSCluster --node-count 10 --nodepool-name <your node pool name>

It acts on the number of nodes which are in your nodepool.

Reference: https://docs.microsoft.com/en-us/azure/aks/scale-cluster

Thank you for your response Jakaruna! I misread the command thought it said autoscale and was wondering if there was a reason for having 2 auto scalers.

To extend on this, is there an auto scaler for nodes? we are using kubectl autoscale for our pods so that when the cpu reaches above a certain treshold (currently 60) we scale an extra pod.

eventually there is no more space for pods in our nodes and we need to upscale the nodes, it this something that can be handled automatically?

az aks scale is for the nodes . But using that command you can scale manually.

You can also setup automatic scaling on AKS. Thats called as cluster autoscaler.

This doc will help you to setup the cluster autoscaler.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

monteledwards picture monteledwards  Â·  3Comments

JamesDLD picture JamesDLD  Â·  3Comments

varma31 picture varma31  Â·  3Comments

bityob picture bityob  Â·  3Comments

Ponant picture Ponant  Â·  3Comments