autoscaler/cluster-autoscaler
Kubernetes Prow Robot 2cd1870d6a
Merge pull request #3295 from johnzheng1975/patch-1
Update README.md
2020-08-19 01:53:10 -07:00
..
cloudprovider Merge pull request #3312 from detiber/unstructured 2020-08-18 20:25:11 -07:00
clusterstate Migrate to klog v2 2020-06-05 17:22:26 +02:00
config Add support for passing in custom ignore labels 2020-03-17 14:30:03 +11:00
context Migrate to klog v2 2020-06-05 17:22:26 +02:00
core Add an annotation identifying upcoming nodes 2020-07-24 15:20:34 +02:00
estimator Use FitsAnyNode in binpacking 2020-08-13 15:34:14 +02:00
expander Fix priority expander falling back to random although higher priority matches 2020-07-31 07:14:36 +02:00
hack Use shallow clone in update-vendor.sh 2020-08-10 12:55:37 +02:00
metrics Migrate to klog v2 2020-06-05 17:22:26 +02:00
processors Merge pull request #3124 from JoelSpeed/memory-tolerance-quantity 2020-06-24 04:25:17 -07:00
proposals Address recent breaking changes in scheduler 2020-04-24 17:54:47 +02:00
simulator Add the ability to check if a pod fits onto any node matching a function 2020-07-24 15:15:23 +02:00
utils Merge pull request #3040 from johanneswuerbach/aws-impaired-vols 2020-07-06 02:10:52 -07:00
vendor Merge pull request #3312 from detiber/unstructured 2020-08-18 20:25:11 -07:00
version Bump CA version to 1.19.0-beta.1 2020-07-20 13:20:38 +02:00
.gitignore priority expander 2019-03-22 10:43:20 +01:00
Dockerfile Drop run.sh and use distroless as base image for CA 2019-06-11 23:40:03 +02:00
FAQ.md Fix wrong default value for expendable-pods-priority-cutoff in FAQ 2020-08-04 15:25:52 +02:00
Makefile Disable go.mod integration in Makefile (remainder) 2020-01-03 15:31:36 +01:00
OWNERS Add myself to owners 2020-08-03 18:49:46 +08:00
README.md Update README.md 2020-07-07 10:38:45 +08:00
cloudbuild.yaml Add GCB config for cluster-autoscaler 2018-02-15 16:03:35 -08:00
fix_gopath.sh Bug with with globbing 2019-04-08 10:18:41 +10:00
go.mod Updating vendor against git@github.com:kubernetes/kubernetes.git:master (dbf66e9be31ee4041e2dfaf428b7b7202c7942cc) 2020-08-08 12:57:33 +08:00
go.mod-extra Remove github.com/aws/aws-sdk-go v1.23.18 from go.mod-extra 2020-02-04 20:51:02 +01:00
go.sum Updating vendor against git@github.com:kubernetes/kubernetes.git:master (dbf66e9be31ee4041e2dfaf428b7b7202c7942cc) 2020-08-08 12:57:33 +08:00
main.go Fixes after vendor update 2020-06-05 17:22:26 +02:00
main_test.go Fix error format strings according to best practices from CodeReviewComments 2019-01-11 09:10:31 +13:00
push_image.sh Pushes go to staging-k8s.gcr.io 2018-01-17 14:16:38 -08:00
update_toc.py

README.md

Cluster Autoscaler

Introduction

Cluster Autoscaler is a tool that automatically adjusts the size of the Kubernetes cluster when one of the following conditions is true:

  • there are pods that failed to run in the cluster due to insufficient resources.
  • there are nodes in the cluster that have been underutilized for an extended period of time and their pods can be placed on other existing nodes.

FAQ/Documentation

An FAQ is available HERE.

You should also take a look at the notes and "gotchas" for your specific cloud provider:

Releases

We recommend using Cluster Autoscaler with the Kubernetes master version for which it was meant. The below combinations have been tested on GCP. We don't do cross version testing or compatibility testing in other environments. Some user reports indicate successful use of a newer version of Cluster Autoscaler with older clusters, however, there is always a chance that it won't work as expected.

Starting from Kubernetes 1.12, versioning scheme was changed to match Kubernetes minor releases exactly.

Kubernetes Version CA Version
1.16.X 1.16.X
1.15.X 1.15.X
1.14.X 1.14.X
1.13.X 1.13.X
1.12.X 1.12.X
1.11.X 1.3.X
1.10.X 1.2.X
1.9.X 1.1.X
1.8.X 1.0.X
1.7.X 0.6.X
1.6.X 0.5.X, 0.6.X*
1.5.X 0.4.X
1.4.X 0.3.X

*Cluster Autoscaler 0.5.X is the official version shipped with k8s 1.6. We've done some basic tests using k8s 1.6 / CA 0.6 and we're not aware of any problems with this setup. However, Cluster Autoscaler internally simulates Kubernetes' scheduler and using different versions of scheduler code can lead to subtle issues.

Notable changes

For CA 1.1.2 and later, please check release notes.

CA version 1.1.1:

  • Fixes around metrics in the multi-master configuration.
  • Fixes for unready nodes issues when quota is overrun.

CA version 1.1.0:

CA version 1.0.3:

  • Adds support for safe-to-evict annotation on pod. Pods with this annotation can be evicted even if they don't meet other requirements for it.
  • Fixes an issue when too many nodes with GPUs could be added during scale-up (https://github.com/kubernetes/kubernetes/issues/54959).

CA Version 1.0.2:

CA Version 1.0.1:

CA Version 1.0:

With this release we graduated Cluster Autoscaler to GA.

  • Support for 1000 nodes running 30 pods each. See: Scalability testing report
  • Support for 10 min graceful termination.
  • Improved eventing and monitoring.
  • Node allocatable support.
  • Removed Azure support. See: PR removing support with reasoning behind this decision
  • cluster-autoscaler.kubernetes.io/scale-down-disabled annotation for marking nodes that should not be scaled down.
  • scale-down-delay-after-delete and scale-down-delay-after-failure flags replaced scale-down-trial-interval

CA Version 0.6:

CA Version 0.5.4:

  • Fixes problems with node drain when pods are ignoring SIGTERM.

CA Version 0.5.3:

CA Version 0.5.2:

CA Version 0.5.1:

CA Version 0.5:

  • CA continues to operate even if some nodes are unready and is able to scale-down them.
  • CA exports its status to kube-system/cluster-autoscaler-status config map.
  • CA respects PodDisruptionBudgets.
  • Azure support.
  • Alpha support for dynamic config changes.
  • Multiple expanders to decide which node group to scale up.

CA Version 0.4:

  • Bulk empty node deletions.
  • Better scale-up estimator based on binpacking.
  • Improved logging.

CA Version 0.3:

  • AWS support.
  • Performance improvements around scale down.

Deployment

Cluster Autoscaler is designed to run on Kubernetes master node. This is the default deployment strategy on GCP. It is possible to run a customized deployment of Cluster Autoscaler on worker nodes, but extra care needs to be taken to ensure that Cluster Autoscaler remains up and running. Users can put it into kube-system namespace (Cluster Autoscaler doesn't scale down node with non-mirrored kube-system pods running on them) and set a priorityClassName: system-cluster-critical property on your pod spec (to prevent your pod from being evicted).

Supported cloud providers: