mgr/cephadm: upgrade multiple OSDs in parallel#39726
Merged
liewegas merged 7 commits intoceph:masterfrom Mar 4, 2021
Merged
Conversation
Member
Author
|
jenkins test make check |
|
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
c1b31f6 to
3a431b4
Compare
| j = json.loads(r.stdout) | ||
| except json.decoder.JSONDecodeError: | ||
| self.mgr.log.warning("osd ok-to-stop didn't return structur result") | ||
| pass |
Contributor
There was a problem hiding this comment.
raise
I'd be 👍 for seeing tracker issues, if ok-to-stop returns something invalie.
| break | ||
|
|
||
| num = 1 | ||
| for d in to_upgrade: |
Contributor
There was a problem hiding this comment.
you need use @cephadm.utils.forall_hosts in order to make this in parallel.
Member
Author
There was a problem hiding this comment.
i'm not sure it's necessary to parallelize this tbh.. leaving that as a future optimization
Signed-off-by: Sage Weil <sage@newdream.net>
Optionally provide a list of previously known-to-be-ok-to-stop items to the ok_to_stop method. This has to get plumbed through a zillion instances of this class method. No functional change (yet). Signed-off-by: Sage Weil <sage@newdream.net>
Signed-off-by: Sage Weil <sage@newdream.net>
Restart multiple osds in a single upgrade pass, when possible. Signed-off-by: Sage Weil <sage@newdream.net>
Signed-off-by: Sage Weil <sage@newdream.net>
This message is shown during the upgrade process. Signed-off-by: Sage Weil <sage@newdream.net>
3a431b4 to
fb778a3
Compare
| to_upgrade.append(d) | ||
| continue | ||
|
|
||
| if not self._wait_for_ok_to_stop(d, known_ok_to_stop): |
Contributor
There was a problem hiding this comment.
took me a while to figure out that _wait_for_ok_to_stop changes known_ok_to_stop in this loop
Signed-off-by: Sage Weil <sage@newdream.net>
sebastian-philipp
approved these changes
Mar 4, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Make use of the new ok-to-stop structured output and --max argument to expand the list of OSDs to restart, speeding up upgrades.
Checklist
Show available Jenkins commands
jenkins retest this pleasejenkins test classic perfjenkins test crimson perfjenkins test signedjenkins test make checkjenkins test make check arm64jenkins test submodulesjenkins test dashboardjenkins test apijenkins test docsjenkins render docsjenkins test ceph-volume alljenkins test ceph-volume tox