Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: How to limit the max size of a cluster? #1104

Closed
StarpTech opened this issue Jan 7, 2022 · 4 comments
Closed

Question: How to limit the max size of a cluster? #1104

StarpTech opened this issue Jan 7, 2022 · 4 comments
Labels
documentation Improvements or additions to documentation

Comments

@StarpTech
Copy link

StarpTech commented Jan 7, 2022

Hi, how can I ensure the maximum number of nodes? Will karpenter respect the configuration of a managed eks cluster (eskctl maxSize)?

@StarpTech StarpTech added the bug Something isn't working label Jan 7, 2022
@StarpTech StarpTech changed the title Question: How to limit the max size of cluster? Question: How to limit the max size of a cluster? Jan 7, 2022
@cest-pas-faux
Copy link
Contributor

Hi,
You cannot specify yet a max number of nodes, but a workaround may to fine-tune your instance types and assign a hard resources limit as shown in the example config : https://karpenter.sh/docs/getting-started/#provisioner

@ellistarn ellistarn added documentation Improvements or additions to documentation and removed bug Something isn't working labels Jan 7, 2022
@ellistarn
Copy link
Contributor

You can specify max resources spec.limits.resources. We need to document this. Closing as dup of #1003.

@olemarkus
Copy link
Contributor

Just a thought here. Just like you have maxPods in addition to cpu/mem, it does make sense to have max nodes. From control plane perspective, each node does have some overhead. That's why it is quite common for e.g CNIs to specify scaling thresholds both in terms of number of pods in the cluster and number of nodes.

Granted, some of this should be mitigated by disallowing nodes that are too small, it is still not that unreasonable. Somewhat related to the defrag problem in #1091, karpenter could consider growing the instance sizes when the "maxNodes" limit is approaching.

@StarpTech
Copy link
Author

@adefrasne @ellistarn thanks, this is what I'm looking for. I want to avoid that an infinite number of nodes are provisioned. We use karpenter to deploy preview environments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

4 participants