-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
mgr/cephadm: make SMB and NVMEoF upgrade last in staggered upgrade #57292
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks OK to me.
src/pybind/mgr/cephadm/upgrade.py
Outdated
# no ceph daemons need upgrade | ||
dds = [d for d in self.mgr.cache.get_daemons_by_type( | ||
daemon_type) if d.name() not in need_upgrade_names] | ||
_, __, n2, ___ = self._detect_need_upgrade(dds, target_digests, target_image) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would have gone for n2 = self._detect_need_upgrade(...)[2]
but this is fine for now.
jenkins test make check |
failures:
Overall, nothing unexpected in the run |
This needs to happen as some work on the NVMEoF side (still unmerged as of writing this) will make the NVMEoF daemon dependent on the mon. Prior to this patch, in a staggered upgrade, all daemons not using the ceph image were upgraded after the mgr since we typically only care about the default image changing or potential changes to how we handle our systemd units which only needs the mgr to be upgraded to be applied. This NVMEoF dependency on the mon changes this and we can no longer upgrade it directly after the mgr. This patch changes it so the NVMEoF daemon is instead upgraded after all ceph image daemons have been upgraded in a staggered upgrade scenario. Non-staggered upgrades are unaffected as the NVMEoF daemon was already upgraded near the end in that scenario. The SMB dameon has no reason it needs to be upgraded later, but it's in the (small) pool of daemons that don't use the ceph image and aren't for monitoring, so it's been affected by this as well. NOTE: This is a bit of an ugly patch imo and shows that a refactoring of the upgrade code is likely required. Hopefully this patch is more of a stopgap until that larger effort can be made Fixes: https://tracker.ceph.com/issues/65809 Signed-off-by: Adam King <adking@redhat.com>
45d9054
to
5e7a3c2
Compare
jenkins test api |
This needs to happen as some work on the NVMEoF side (still unmerged as of writing this) will make the NVMEoF daemon dependent on the mon. Prior to this patch, in a staggered upgrade, all daemons not using the ceph image were upgraded after the mgr since we typically only care about the default image changing or potential changes to how we handle our systemd units which only needs the mgr to be upgraded to be applied. This NVMEoF dependency on the mon changes this and we can no longer upgrade it directly after the mgr. This patch changes it so the NVMEoF daemon is instead upgraded after all ceph image daemons have been upgraded in a staggered upgrade scenario. Non-staggered upgrades are unaffected as the NVMEoF daemon was already upgraded near the end in that scenario. The SMB dameon has no reason it needs to be upgraded later, but it's in the (small) pool of daemons that don't use the ceph image and aren't for monitoring, so it's been affected by this as well.
NOTE: This is a bit of an ugly patch imo and shows that a refactoring of the upgrade code is likely required. Hopefully this patch is more of a stopgap until that larger effort can be made
Fixes: https://tracker.ceph.com/issues/65809
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an
x
between the brackets:[x]
. Spaces and capitalization matter when checking off items this way.Checklist
Show available Jenkins commands
jenkins retest this please
jenkins test classic perf
jenkins test crimson perf
jenkins test signed
jenkins test make check
jenkins test make check arm64
jenkins test submodules
jenkins test dashboard
jenkins test dashboard cephadm
jenkins test api
jenkins test docs
jenkins render docs
jenkins test ceph-volume all
jenkins test ceph-volume tox
jenkins test windows
jenkins test rook e2e