Skip to content

rgw/multisite: keep the period id when pulling a period from the master - #72671

Merged
anrao19 merged 1 commit into
ceph:mainfrom
lumir-sliva:rgw-period-puller-keep-period-id
Nov 3, 2026
Merged

anrao19 merged 1 commit into
ceph:mainfrom
lumir-sliva:rgw-period-puller-keep-period-id

Conversation

@lumir-sliva

Copy link
Copy Markdown
Contributor

RGWPeriodPuller::pull() fetches a period the zone doesn't have yet from the metadata master and stores it. Since the configstore refactor in 976889f it first gives the pulled period a new random id and resets its epoch to 1, which looks like a copy of the "create a new period" step of a period commit. Every gateway that pulls a period stores it under its own made-up id.

The pull path runs when a zone missed a period push, for example a zone that was down while the master moved. Its metadata sync then walks the period history with that made-up id, finds no mdlog for it on the master, and stays on that realm epoch for good.

The fix stores the pulled period as it came, as store_info() did before the refactor. Not in squid or tentacle, so no backport.

Tested with test_multi_period_incremental_sync, where the third zone is down while the master moves and then pulls the latest period:

  • without the fix (1 gateway per zone): fails, the third zone walks realm epoch 3 under a random id instead of the real one; with 2 gateways per zone the two gateways of that zone log two different ids for the same period
  • with the fix (together with the metadata sync fixes for more than one gateway per zone in rgw/multisite: fix metadata sync of past periods #72670): the third zone walks the real ids for epochs 2, 3 and 4, 5 of 5 runs pass

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

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
    • Includes unit test(s)
    • Includes integration test(s)
    • Includes bug reproducer
    • No tests

RGWPeriodPuller::pull() fetches a period this zone doesn't have yet from
the metadata master, then stores it. Since the configstore refactor in
976889f it gives the pulled period a new random id and resets its
epoch to 1 before storing it, a copy of the "create a new period" step of
a period commit. Every gateway that pulls a period therefore stores it
under its own made-up id.

The pull path runs when a zone missed a period push, for example a zone
that was down while the master moved. Its metadata sync then walks the
period history with that made-up id, can't find the period's mdlog on the
master, and never gets past it. test_multi_period_incremental_sync shows
it: the zone that was stopped stays on the pulled realm epoch, and its two
gateways log two different period ids for that epoch.

Store the pulled period as it came, like store_info() did before the
refactor.

Introduced by 976889f ("RGW/standalone: refactor RGWPeriod with
configstore").

Fixes: https://tracker.ceph.com/issues/81758
Signed-off-by: Lumir Sliva <[email protected]>
@lumir-sliva
lumir-sliva requested a review from a team as a code owner October 14, 2026 10:07
@github-actions

Copy link
Copy Markdown

Thank you for your contribution. Since you are not yet a member of the Ceph organization with write permissions on ceph/ceph.git, our CI will not automatically run. Any member of the Ceph organization may label this PR ci-approved to allow Jenkins CI jobs to run.

@anrao19

anrao19 commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

This PR has been added to main integration testing by anuchaithra started 2026-10-16-04:48.

@anrao19

anrao19 commented Nov 2, 2026

Copy link
Copy Markdown
Contributor

This PR has been added to main integration testing by anuchaithra started 2026-10-16-04:48.

pr testing completed and approved by @ivancich , more details in : https://tracker.ceph.com/issues/81819.
@lumir-sliva, if no further testing is needed then this pr can be merged

@anrao19
anrao19 merged commit d040898 into ceph:main Nov 3, 2026
21 checks passed
@github-actions

github-actions Bot commented Nov 3, 2026

Copy link
Copy Markdown

This is an automated message by src/script/redmine-upkeep.py.

I have resolved the following tracker ticket due to the merge of this PR:

No backports are pending for the ticket. If this is incorrect, please update the tracker
ticket and reset to Pending Backport state.

Update Log: https://github.com/ceph/ceph/actions/runs/41614128541

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants