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

A job evaluation stops allocations before missing allocations are started #3053

Closed
clinta opened this issue Aug 18, 2017 · 1 comment
Closed

Comments

@clinta
Copy link
Contributor

clinta commented Aug 18, 2017

Nomad version

v0.6.0

Operating system and Environment details

Ubuntu 16.04

If you have a job with max_parallel set to 1 and a count of some higher number, say 5, then you update the job with an invalid configuration which causes the allocation to fail, the evaluation will, as expected, stop one allocation, try to start one new allocation and fail to do so. The deployment will fail and the 4 existing allocations will continue running as expected.

If you then trigger a gc via the nomad api, the failed allocation will be deleted. Then trigger a re-evaluation of the same job. The reevaluation will stop another running allocation, leaving you with only 3 running allocations and will try to start up two failed allocations.

You can keep doing this, losing one running allocation each time.

The evaluation should take into account that you only have 4 of 5 desired allocations running, and try to start the missing allocation and make sure it is healthy before shutting down any additional allocations. It should never shut down allocations if doing so would result in more than max_parallel allocations being down.

dadgar added a commit that referenced this issue Aug 21, 2017
This PR makes placing new allocations count towards the limit. We do not
restrict how many new placements are made by the limit but we still
count towards the limit. This has the nice affect that if you have a
group with count = 5 and max_parallel = 1 but only 3 allocs exist for it
and a change is made, you will create 2 more at the new version but not
destroy one, taking you down to two running as you would have
previously.

Fixes #3053
@github-actions
Copy link

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.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants