Cluster autoscaling not working, no cluster nodes processed by cluster autoscaler
search cancel

Cluster autoscaling not working, no cluster nodes processed by cluster autoscaler

book

Article ID: 313122

calendar_today

Updated On:

Products

VMware

Issue/Introduction

Symptoms:

Cluster Autoscaling failing and autoscaler pods does not recognise any of the Worker nodes for autoscaler processing.

I0322 11:04:23.266540 1 static_autoscaler.go:541] Calculating unneeded nodes
I0322 11:04:23.266603 1 pre_filtering_processor.go:57] Node tkg-xxx-md-0-75c6d9f47bxzncc8-sm4lw should not be processed by cluster autoscaler (no node group config)
I0322 11:04:23.266722 1 pre_filtering_processor.go:57] Node tkg-xxx-md-0-75c6d9f47bxzncc8-dbrh5 should not be processed by cluster autoscaler (no node group config)

 

 

 

Environment

VMware Tanzu Kubernetes Grid Plus 1.x

Cause

The machine deployment does not have the correct annotations and it is dependent on the TKG version.
TKG 1.6

kind: MachineDeployment
metadata:
  annotations:
    cluster.k8s.io/cluster-api-autoscaler-node-group-max-size: "20"
    cluster.k8s.io/cluster-api-autoscaler-node-group-min-size: "5"


TKG 2.1 and later

kind: MachineDeployment
metadata:
  annotations:
    cluster.x-k8s.io/cluster-api-autoscaler-node-group-max-size: "20"
    cluster.x-k8s.io/cluster-api-autoscaler-node-group-min-size: "5"

 

Resolution

Updated Machinedeployment with the correct annotation