Feedback

Chat Icon

End-to-End Kubernetes with Rancher, RKE2, K3s, Fleet, Longhorn, and NeuVector

The full journey from nothing to production

Autoscaling RKE2 Clusters with Rancher
95%

Cluster Autoscaler: Dynamic Scaling of Kubernetes Clusters

The Cluster Autoscaler is a Kubernetes tool developed by the same community that maintains Kubernetes. It is designed to dynamically manage the size of a cluster based on resource demands. It increases the number of nodes when there are pods that cannot be scheduled due to insufficient resources. Conversely, it reduces the number of nodes when some nodes are underutilized for an extended period, and their workloads can be redistributed to other nodes.

ℹ️ Cost optimization, availability, and performance are the main benefits of using the Cluster Autoscaler. This is why it's an important tool to consider in your production environment.

It's worth noting that not every Kubernetes cluster needs to be autoscaled, and not every cluster can be autoscaled: you need a cloud provider that supports autoscaling. For example, AWS, GCP, and Azure all support autoscaling, while some other providers do not. In our context, we are using RKE2 as a Kubernetes distribution, DigitalOcean as a cloud provider, and Rancher as a management platform. We have two options to enable autoscaling:

  • Using Rancher Autoscaler: This cluster autoscaler for Rancher scales nodes in clusters that use RKE2 provisioning (Rancher v2.6+). It uses a combination of the Rancher API and the underlying cluster-api types of RKE2.

  • Using DigitalOcean Autoscaler: The cluster autoscaler for DigitalOcean scales worker nodes within any specified DigitalOcean Kubernetes cluster's node pool. This is part of the DOKS offering which can be enabled/disabled dynamically for an existing cluster.

End-to-End Kubernetes with Rancher, RKE2, K3s, Fleet, Longhorn, and NeuVector

The full journey from nothing to production

Enroll now to unlock all content and receive all future updates for free.