Bug 1448084

Summary: [rbd-mirror] : manually removing a replicated image might result in an empty image
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Jason Dillaman <jdillama>
Component: RBDAssignee: Jason Dillaman <jdillama>
Status: CLOSED ERRATA QA Contact: Tejas <tchandra>
Severity: medium Docs Contact: Aron Gunn <agunn>
Priority: low    
Version: 2.3CC: agunn, ceph-eng-bugs, ceph-qe-bugs, tchandra, uboppana
Target Milestone: z1   
Target Release: 2.5   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ceph-10.2.10.el7cp Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-07-26 18:06:41 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jason Dillaman 2017-05-04 13:43:42 UTC
Description of problem:
After a forced-failover event from site A to site B, if you delete the image on site A (while it's still primary) via "rbd rm <image-spec>", rbd-mirror will correctly detect that it should replicate the image from site B back to site A. Unfortunately, it skips the actual image sync step and just creates an empty image.

Restarting the rbd-mirror daemon on site A or requesting a manual resync will correct the issue.

Version-Release number of selected component (if applicable):
10.2.x

How reproducible:
100%

Steps to Reproduce:
1. rbd --cluster siteB mirror image promote --force <image-spec>
2. rbd --cluster siteA rm <image-spec>

Actual results:
A blank (zeroed) image will be re-created on siteA

Expected results:
A properly synchronized image will be re-created on siteA

Comment 2 Jason Dillaman 2017-05-04 13:44:56 UTC
Associated master branch PR: https://github.com/ceph/ceph/pull/14945

Comment 3 Jason Dillaman 2018-06-08 20:37:06 UTC
Fix was included under rebase to 10.2.10

Comment 8 errata-xmlrpc 2018-07-26 18:06:41 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:2261