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/PG: fix lost unfound + delete when there are no missing objects #16809

Merged
merged 1 commit into from Aug 4, 2017

Conversation

Projects
None yet
2 participants
@jdurgin
Member

jdurgin commented Aug 4, 2017

The default constructed pg_missing_t for a peer with no missing
objects resets may_include_deletes to false, so when missing items for
lost deletes should be added later, they are not, and the old
version of the lost object is left on the replica.

Fix this by always setting may_include_deletes upon entering the
GetMissing state, and using clear() rather than the default
constructor to create an empty missing set.

This only affects lost_unfound delete since it is the only way for a
peer to gain missing delete entries. If the peer starts out missing
some objects, its missing set sent over the wire is used instead, with
the correct setting for may_include_deletes.

Fixes: http://tracker.ceph.com/issues/20904
Signed-off-by: Josh Durgin jdurgin@redhat.com

osd/PG: fix lost unfound + delete when there are no missing objects
The default constructed pg_missing_t for a peer with no missing
objects resets may_include_deletes to false, so when missing items for
lost deletes should be added later, they are not, and the old
version of the lost object is left on the replica.

Fix this by always setting may_include_deletes upon entering the
GetMissing state, and using clear() rather than the default
constructor to create an empty missing set.

This only affects lost_unfound delete since it is the only way for a
peer to gain missing delete entries. If the peer starts out missing
some objects, its missing set sent over the wire is used instead, with
the correct setting for may_include_deletes.

Fixes: http://tracker.ceph.com/issues/20904
Signed-off-by: Josh Durgin <jdurgin@redhat.com>

@jdurgin jdurgin added this to the luminous milestone Aug 4, 2017

@jdurgin

This comment has been minimized.

@liewegas liewegas merged commit 8b77007 into ceph:master Aug 4, 2017

4 checks passed

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

@jdurgin jdurgin deleted the jdurgin:wip-20904 branch Aug 4, 2017

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