]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
librbd: track in-progress migration aborting operation
authorJason Dillaman <dillaman@redhat.com>
Tue, 4 Aug 2020 21:09:57 +0000 (17:09 -0400)
committerJason Dillaman <dillaman@redhat.com>
Wed, 16 Sep 2020 17:19:29 +0000 (13:19 -0400)
commit423556aab73bb6549022c24b1f56f12ccb2f6031
tree8718f20b414d7728d706b6bc0bf7ab2a0451c47a
parent7face17f58d8c231e47eda4ec8e08aae575503e7
librbd: track in-progress migration aborting operation

We want to prevent the destination image from being used while an
abort is in-progress. Test that the image has no watchers prior to
permitting the abort, switch the migration state to ABORTING, and
treat the image as read-only if the migration state is ABORTING.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit d848b4f1c083bd9f3e6eac3e186c9e7df2e22004)
(cherry picked from commit 2bc5229717326298ca964333fc07a38c5e48701e)

Conflicts:
src/librbd/image/RefreshRequest.cc: lock and read-only flags refactor
src/cls/rbd/cls_rbd_types.cc
src/cls/rbd/cls_rbd_types.h
src/include/rbd/librbd.h
src/librbd/api/Migration.cc
src/librbd/image/RefreshRequest.cc
src/librbd/image/RefreshRequest.h
src/pybind/rbd/rbd.pyx
src/test/librbd/test_Migration.cc
src/tools/rbd/action/Status.cc