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: prevent self-blacklisting during break lock #13110

Merged
merged 1 commit into from Jan 26, 2017

Conversation

dillaman
Copy link

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

Fixes: http://tracker.ceph.com/issues/18666
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
@trociny
Copy link
Contributor

trociny commented Jan 26, 2017

@dillaman just wondering, it looks it would be safer to check address. Do you check entity because there is no rados API for get_myaddr?

Also, if we are breaking without blacklisting, is it ok to self-break?

@dillaman
Copy link
Author

@trociny The client id is a globally unique identifier (and the only one available to us) and the lock itself is attached to the client global id, not its IP address. Do you have a case in mind where this would fail?

We aren't introducing any additional worries if you disabled blacklisting and you attempted to self-break. In that case, it would at least be able to recover the lock (unlike if it blacklisted itself).

@trociny
Copy link
Contributor

trociny commented Jan 26, 2017

@dillaman

Do you have a case in mind where this would fail?

Never mind, I forgot that the address also includes nonce. I was thinking that if an application had two clients, their addresses would match (which is not the case, and actually then our BreakLock tests would not work).

Copy link
Contributor

@trociny trociny left a comment

Choose a reason for hiding this comment

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

LGTM

@trociny trociny merged commit c720e34 into ceph:master Jan 26, 2017
@dillaman dillaman deleted the wip-18666 branch January 26, 2017 22:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants