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

osd: fix _process handling for pg vs slot race #21745

Merged
merged 1 commit into from May 1, 2018

Conversation

Projects
None yet
2 participants
@liewegas
Copy link
Member

commented Apr 30, 2018

No description provided.

@liewegas

This comment has been minimized.

Copy link
Member Author

commented Apr 30, 2018

/a/sage-2018-04-30_00:12:46-rados-wip-sage3-testing-2018-04-29-1658-distro-basic-smithi/2453627

osd: fix _process handling for pg vs slot race
We could see the slot with a different PG than we expected if the old
PG was removed and a new one was instantiated in its place.  We can't
just pick up the new PG pointer, however, since it isn't locked.

Fix by retrying with the slot's new pg (possibly null!).  Move this check
below the other cases so that we know we are otherwise consistent with
the slot, since the next pass around we might get pg==null and skip the
to_process.empty() and requeue_seq checks entirely.

Signed-off-by: Sage Weil <sage@redhat.com>

@liewegas liewegas force-pushed the liewegas:wip-pg-removal-race branch from a7aac76 to 7dbcc77 Apr 30, 2018

@liewegas

This comment has been minimized.

Copy link
Member Author

commented May 1, 2018

@liewegas liewegas requested review from gregsfortytwo and jdurgin May 1, 2018

@gregsfortytwo

This comment has been minimized.

Copy link
Member

commented May 1, 2018

I don't think I understand. The commit message says to bail out, but we're retrying in the code, and I don't see a check that will cause it to bail on that retry that wouldn't have been invoked the first time around.

@liewegas

This comment has been minimized.

Copy link
Member Author

commented May 1, 2018

The commit was updated but hte PR description wasn't :)

@gregsfortytwo
Copy link
Member

left a comment

Reviewed-by: Greg Farnum gfarnum@redhat.com

@liewegas liewegas merged commit edcbb1b into ceph:master May 1, 2018

5 checks passed

Docs: build check OK - docs built
Details
Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check make check succeeded
Details
make check (arm64) make check succeeded
Details

@liewegas liewegas deleted the liewegas:wip-pg-removal-race branch May 1, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.