Bug 2222726 - Disallow enabling snapshot-based mirroring on cloned images
Summary: Disallow enabling snapshot-based mirroring on cloned images
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat Storage
Component: RBD-Mirror
Version: 6.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 6.1z2
Assignee: Ilya Dryomov
QA Contact: Sunil Angadi
Akash Raj
URL:
Whiteboard:
Depends On:
Blocks: 2235257
TreeView+ depends on / blocked
 
Reported: 2023-07-13 14:53 UTC by Shyamsundar
Modified: 2023-11-03 04:01 UTC (History)
13 users (show)

Fixed In Version: ceph-17.2.6-105.el9cp
Doc Type: No Doc Update
Doc Text:
Clone Of:
: 2230076 (view as bug list)
Environment:
Last Closed: 2023-10-12 16:34:33 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 2222814 0 unspecified ASSIGNED parent data is not copied up on incremental deep-copy (when cloned images are mirrored) 2024-03-26 12:03:03 UTC
Red Hat Issue Tracker RHCEPH-7057 0 None None None 2023-07-20 14:17:39 UTC
Red Hat Product Errata RHSA-2023:5693 0 None None None 2023-10-12 16:35:31 UTC

Description Shyamsundar 2023-07-13 14:53:16 UTC
Description of problem:

As "Parent data is not copied up when cloned images are mirrored.", any image that is a clone should be prevented from being mirror enabled.

As a feature DR does not support mirroring volumes that are clones of snapshots or of other volumes. The request in this BZ is to hence enforce the same in code, such that it is never silently ignored as that can cause image corruption as noted in the ceph tracker below.

See related ceph tracker https://tracker.ceph.com/issues/61891

Additional info:

The intent of this bz is for VolumeReplication (VR) to error out enabling replication for images that are clones. Which hence would result in VR never being successfully processed, and the error/state would percolate upwards to layers like Ramen VRG/DRPC and result in the user noting the failure to protect the desired volumes.

Notes:

Ramen VRG detecting a PVC as a clone from a snapshot or another volume if the volume is an RBD backed image is another feasible option. This does not however prevent cases where the image is pre-created and also introduces into Ramen a notion of which storage backend it is dealing with to report errors. As a result adding this in the VolumeReplication relateg EnableReplication gRPC layer is more suited as this is an unsupported feature by the specific storage backend (ceph-RBD in this case).

Comment 4 Niels de Vos 2023-07-14 07:23:19 UTC
It sounds as if this needs to be addressed in Ceph.

If a workaround is needed in Ceph-CSI to report about mirroring cloned images, we need a way to detect what Ceph version does not handle them correctly (assuming a future release supports it). Is there any check that Ceph-CSI can do before starting the mirroring of a cloned image?

Comment 20 errata-xmlrpc 2023-10-12 16:34:33 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 (Moderate: Red Hat Ceph Storage 6.1 security, enhancement, and bug fix update), 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-2023:5693


Note You need to log in before you can comment on or make changes to this bug.