<p>I'd like to run the kubernetes cluster autoscaler so that unneeded nodes will be removed automatically, but I don't want the autoscaler to add nodes automatically. I prefer to handle scaling up myself. Is this possible?</p>

<p>I found maxNodesTotal, but I worry the semantics of setting this to 0 might mean all my nodes will go away. I also found scaleDownEnabled, but no corresponding option for scaling up.</p>

<p>Since you tagged this question with EKS, I will assume you are on AWS. On AWS the ASG (Auto Scaling Group) for each NodeGroup has a Max setting that is honoured by the cluster autoscaler. You can set this to prevent scaling above the set number of nodes. If the Min and Max on the ASG are the same value, then the autoscaler will never scale up or down. If the Min and Max are different, then the autoscaler can scale both up and down between those number of nodes. This is not exactly &quot;never scale up&quot;, but it limits the upper end.</p>
<p>If you have multiple NodeGroups (ASGs), then each one can have different Min and Max nodes values.</p>
<p>You can also configure the cluster autoscaler itself in different ways. For example, you can set the utilization threshold. If a node's utilization fall under this threshold then the cluster autoscaler considers the node for scale down. See <a href="https://github.com/kubernetes/autoscaler/blob/master/cluster-autoscaler/FAQ.md#how-can-i-prevent-cluster-autoscaler-from-scaling-down-non-empty-nodes" rel="nofollow noreferrer">the FAQ</a>.</p>
<p>The FAQ entry above that one may also apply. You can add an annotation to any node you do not want considered for scale down by the cluster autoscaler. Set: <code>kubectl annotate node &lt;nodename&gt; cluster-autoscaler.kubernetes.io/scale-down-disabled=true</code> or annotate the nodes as they are created. You can do this with entries in your AWS node group setup.</p>
