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

reef: mon/OSDMonitor: fix get_min_last_epoch_clean() #55867

Merged
merged 4 commits into from Apr 3, 2024

Conversation

trociny
Copy link
Contributor

@trociny trociny commented Mar 1, 2024

backport tracker: https://tracker.ceph.com/issues/64650


backport of #54999
parent tracker: https://tracker.ceph.com/issues/63883

this backport was staged using ceph-backport.sh version 16.0.0.6848
find the latest version at https://github.com/ceph/ceph/blob/main/src/script/ceph-backport.sh

Previously, an OSD marked out could have been added back to the map upon new beacon sent by the OSD.
If the OSD goes down (after being added back to map) - it won't be marked as OUT again.
Therefore, `osd_epochs` would remain with a "stale" OSD, as a result OSDMonitor::get_min_last_epoch_clean() will always return the "stale" OSD epoch.

When osd is marked out, it will be erased from `osd_epochs` map. Correspondingly, it should be added back to the map **only** once it's marked in.

Fixes: https://tracker.ceph.com/issues/63883

Signed-off-by: Matan Breizman <mbreizma@redhat.com>
(cherry picked from commit dd1d30b)
Signed-off-by: Matan Breizman <mbreizma@redhat.com>
(cherry picked from commit 1f89b68)
OUT OSDs can be the primary for a PG via pg_temp. Therfore, we should
consider OUT as valid beacons.

Signed-off-by: Matan Breizman <mbreizma@redhat.com>
(cherry picked from commit ba750f4)
Co-authored-by: Samuel Just <sjust@redhat.com>
Signed-off-by: Matan Breizman <mbreizma@redhat.com>
(cherry picked from commit 685047b)
@trociny trociny requested a review from a team as a code owner March 1, 2024 12:00
@trociny trociny added this to the reef milestone Mar 1, 2024
@trociny trociny added the core label Mar 1, 2024
@github-actions github-actions bot added the mon label Mar 1, 2024
@Matan-B Matan-B requested a review from rzarzynski March 3, 2024 10:28
Copy link
Contributor

@pereman2 pereman2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yuriw yuriw merged commit d181828 into ceph:reef Apr 3, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants