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

rbd-mirror: check remote image mirroring state when bootstrapping #12820

Merged
merged 3 commits into from Jan 12, 2017

Conversation

Projects
None yet
2 participants
@trociny
Copy link
Contributor

trociny commented Jan 8, 2017

Fixes: http://tracker.ceph.com/issues/18447
Signed-off-by: Mykola Golub mgolub@mirantis.com

@trociny trociny requested a review from dillaman Jan 8, 2017

@trociny

This comment has been minimized.

Copy link
Contributor Author

trociny commented Jan 8, 2017

@dillaman If you agree with the fix I will remade it with async calls (for both mirror_image_get and is_tag_owner).

@dillaman

This comment has been minimized.

Copy link
Contributor

dillaman commented Jan 8, 2017

@trociny lgtm

@trociny trociny force-pushed the trociny:wip-18447 branch from 55ebc25 to e5b9a32 Jan 9, 2017

@trociny trociny changed the title [DNM] rbd-mirror: check mirroring is enabled for remote image when bootstrapping rbd-mirror: check remote image mirroring state when bootstrapping Jan 9, 2017

@trociny

This comment has been minimized.

Copy link
Contributor Author

trociny commented Jan 9, 2017

@dillaman converted to async

* IS_TAG_OWNER * * * * * * * (error)
* | *
* v *
* <finish> * * * * * * * * *

This comment has been minimized.

Copy link
@dillaman

dillaman Jan 9, 2017

Contributor

Nit: arrow "<" pointer to finish state

@trociny trociny force-pushed the trociny:wip-18447 branch from e5b9a32 to 88311e0 Jan 9, 2017

@trociny

This comment has been minimized.

Copy link
Contributor Author

trociny commented Jan 9, 2017

@dillaman updated

@trociny

This comment has been minimized.

Copy link
Contributor Author

trociny commented Jan 9, 2017

@dillaman I just noticed there is still is_tag_owner sync call. I think it would be a good idea to update it to use IsPrimaryRequest too?

@dillaman

This comment has been minimized.

Copy link
Contributor

dillaman commented Jan 9, 2017

@trociny You mean in OpenLocalImageRequest? Sounds good to me to replace it while working here.

Mykola Golub added some commits Jan 9, 2017

Mykola Golub
rbd-mirror: hold owner lock when testing if lock owner
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
Mykola Golub
rbd-mirror: async request to test if image is primary
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
Mykola Golub
rbd-mirror: check image mirroring state when bootstrapping
Fixes: http://tracker.ceph.com/issues/18447
Signed-off-by: Mykola Golub <mgolub@mirantis.com>

@trociny trociny force-pushed the trociny:wip-18447 branch from 88311e0 to 5fc5a8a Jan 9, 2017

@trociny

This comment has been minimized.

Copy link
Contributor Author

trociny commented Jan 9, 2017

@dillaman Yes, sorry, I meant OpenLocalImageRequest. Updated.

Not sure only if it is safe that now we check primary status no holding owner_lock?

@dillaman

This comment has been minimized.

Copy link
Contributor

dillaman commented Jan 9, 2017

@trociny The lock should have only been there for protecting access to ImageCtx::exclusive_lock

@dillaman dillaman merged commit 60c3667 into ceph:master Jan 12, 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

@trociny trociny deleted the trociny:wip-18447 branch Jan 12, 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.