-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Add "spread" behavior for job placement #1411
Comments
My current workaround for this is something like:
This emulates the spread behavior, but only a bit. I still end up with my first two nodes bearing all the burden while my third node sits idly by. It also doesn't take into account the fact that, even if I were down to a single node, I'd want 2 copies running -- Nomad would be unable to maintain that. Granted, it's a bit silly since in 1-of-3 surviving situation, Nomad would lose consensus and "halt". However, if you consider desiring 5 containers in a 7 node cluster -- lose 3 machines, keep consensus, but only be able to run 4 of the desired containers due to constraints, that's perhaps a better illustrations of how this workaround begins to fail. |
Hey, I would like to clarify. Within a job there is an implicit spread policy, but cluster wide behavior is to bin-pack. So in your example, if you do not explicitly need to have them run on distinct hosts you can just forgo that option. I am going to close this because we do not want to promote a spread behavior as it is suboptimal scheduling behavior for a cluster as a whole and within jobs this already exists. Thanks, |
I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues. |
As written here Nomad currently employs a 'bin packing' algorithm for job placement. Meaning that, as you run more and more jobs Nomad will always try to "fill up" the first node before placing jobs on other nodes. While most efficient, it has a utilization/risk trade off (covered better over herehere).
Currently Nomad is lacking the functionality to allow operators to choose how to distribute jobs between these two options.
The text was updated successfully, but these errors were encountered: