]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
rbd-mirror: fix group replayer deleting the previous mirror group snapshot
authorPrasanna Kumar Kalever <prasanna.kalever@redhat.com>
Fri, 20 Jun 2025 10:52:46 +0000 (16:22 +0530)
committerIlya Dryomov <idryomov@gmail.com>
Sun, 28 Sep 2025 18:25:05 +0000 (20:25 +0200)
commit1959bfa1b5bdef118f980f6f6042af4ff7f8db80
tree9fcbe44e4a0a36c8a3f14bd3177e4d0f34983a6d
parent15b2b086d0e5b058dfdfa5000fb3badd9cec07ce
rbd-mirror: fix group replayer deleting the previous mirror group snapshot

The prune logic in the group replayer currently holds the previous
group snapshot until the current group snapshot syncing is complete.
Hence there is always a previous group snapshot (and the respective
image snapshots).

But when there are user group snapshots group replayer takes them to
account and prunes the previous mirror snapshots, which shouldn't be done.
The group replayer should always hold the previous mirror group snapshot
(irrespective of the user group snap).

Also rename unlink_group_snapshots() -> prune_group_snapshots() and
substitute the use of unlink with prune as required.

Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
src/tools/rbd_mirror/group_replayer/Replayer.cc
src/tools/rbd_mirror/group_replayer/Replayer.h