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

librbd: reduce potential of erroneous blacklisting on image close #15162

Merged
merged 3 commits into from May 22, 2017

Conversation

Projects
None yet
2 participants
@dillaman
Copy link
Contributor

dillaman commented May 19, 2017

No description provided.

@trociny trociny self-assigned this May 19, 2017


if (m_refreshed_locker != m_locker || m_refreshed_locker == Locker{}) {
ldout(m_cct, 5) << "no longer lock owner" << dendl;
finish(-EAGAIN);

This comment has been minimized.

Copy link
@trociny

trociny May 19, 2017

Contributor

@dillaman If get_locker returns -ENOENT, BreakRequest returns with -EAGAIN, and acquire_request will fail with -EAGAIN too though it could succeed.

Note, if break_lock returns -ENOENT below, we return success.

This comment has been minimized.

Copy link
@dillaman

dillaman May 19, 2017

Author Contributor

Good point -- I'll push an update in a few

dillaman added some commits May 18, 2017

librbd: recheck current lock owner before blacklist
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
librbd: introduced support for blocking watch notifications
Signed-off-by: Jason Dillaman <dillaman@redhat.com>

@dillaman dillaman force-pushed the dillaman:wip-19970 branch from da45689 to 421dd0a May 19, 2017

@trociny
Copy link
Contributor

trociny left a comment

otherwise lgtm

CephContext *cct = m_image_ctx->cct;
ldout(cct, 10) << this << " " << __func__ << dendl;

// prevent incoming requests from our peers

This comment has been minimized.

Copy link
@trociny

trociny May 19, 2017

Contributor

@dillaman This comment looks like not needed here?

librbd: block RPC requests before unregistering watch during close
The watch should be released after exclusive lock is released to
avoid a potential race condition which would result in the
client being blacklisted by a peer.

Fixes: http://tracker.ceph.com/issues/19970
Signed-off-by: Jason Dillaman <dillaman@redhat.com>

@dillaman dillaman force-pushed the dillaman:wip-19970 branch from 421dd0a to 13adcac May 19, 2017

@trociny trociny merged commit 1367ab2 into ceph:master May 22, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details

@dillaman dillaman deleted the dillaman:wip-19970 branch May 22, 2017

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.