Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How does the AKS cluster autoscaler behave when there are multiple node pools?

I would like to know how does the AKS cluster autoscaler choses in which node pool to add a node in a multiple node pool environment

For instance, if I have a node pool tainted for a specific applications, will the autoscaler automatically detect the taint and only scale the node pool up if there are some pending pods which can be scheduled on the nodes ? Or will it scale a random node pool in the cluster ?

There is nothing about it on https://learn.microsoft.com/en-us/azure/aks/cluster-autoscaler.

like image 217
Dzack Avatar asked Oct 14 '25 23:10

Dzack


1 Answers

Below are my test results:

Scenario1:

If there are multiple nodepools and if all those nodepools have got corresponding taints applied , then cluster autoscaler will scale only that particular nodepool for which the corresponding pods are in pending state which are specified with tolerations i.e. it will scale only that nodepool which matches with corresponding taints/tolerations

Scenario2:

If you have 3 nodepools , taint is applied only on one nodepool - once the corresponding nodepool is full , then the pending pods can go to other nodepools (on which taints were not applied) and there is a high possibility of auto-scaling randomly the other nodepools also!

Please Note: Only Taints & Tolerations will not guarantee of sticking the pods to corresponding nodepools. But If you apply Taints/Tolerations along with NodeAffinity that will make sure the pods will go and deploy only on corresponding nodepools !

All those conclusions are based upon the tests which I did locally in my AKS cluster!

like image 92
Shiva Patpi Avatar answered Oct 17 '25 13:10

Shiva Patpi