Bug 1973271 - [RBD] Disable thick PVC snapshot to thin PVC restore and thin PVC snapshot to thick PVC restore
Summary: [RBD] Disable thick PVC snapshot to thin PVC restore and thin PVC snapshot to...
Keywords:
Status: VERIFIED
Alias: None
Product: Red Hat OpenShift Container Storage
Classification: Red Hat Storage
Component: csi-driver
Version: 4.8
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: OCS 4.8.0
Assignee: Nobody
QA Contact: Jilju Joy
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-06-17 14:11 UTC by Jilju Joy
Modified: 2023-08-03 08:29 UTC (History)
3 users (show)

Fixed In Version: 4.8.0-432.ci
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github ceph ceph-csi pull 2174 0 None open rbd: add validation for thick restore/clone 2021-06-17 15:26:04 UTC
Github openshift ceph-csi pull 60 0 None open BUG 1973271: rbd: add validation for thick restore/clone 2021-06-18 11:08:19 UTC

Description Jilju Joy 2021-06-17 14:11:48 UTC
Description of problem (please be detailed as possible and provide log
snippests):
With the fix of the bug #1959793, thick PVC snapshot to thick PVC restore and thick PVC to thick PVC clone will be enabled.

Currently all restored RBD PVCs are thin provisioned despite the fact  that the storage class used to restore the snapshot have thick provision enabled or not.

As per the discussions done so far, disabling the scenarios given below will avoid any unforeseen issue even after the fix of #1959793 and also helps smooth 
smooth functioning of thick to thick restore and clone.
1) thick PVC snapshot - thin PVC restore 
2) thin PVC snapshot - thick PVC restore
An upstream PR is already present to which will disable this.
https://github.com/ceph/ceph-csi/pull/2174

Version of all relevant components (if applicable):
OCS 4.8

Comment 6 Mudit Agarwal 2021-06-24 13:21:30 UTC
Though we have disabled the switch between thick to thin and vice versa but it is an open issue in case that is also a requirement.
Tagging this as a known issue, till we have some clarity on the same.

Comment 7 Jilju Joy 2021-07-06 12:48:20 UTC
Verified in version:
ocs-operator.v4.8.0-443.ci
OCP 4.8.0-0.nightly-2021-07-04-112043

Error while creating a thin PVC from the snapshot of a RBD thick PVC:

Generated from openshift-storage.rbd.csi.ceph.com_csi-rbdplugin-provisioner-5f656cc8f7-t9z6l_2f55c1c2-b209-41fd-a91d-2e27956c7ace

failed to provision volume with StorageClass "ocs-storagecluster-ceph-rbd": rpc error: code = InvalidArgument desc = cannot restore from snapshot ocs-storagecluster-cephblockpool/csi-vol-aa7a66df-de52-11eb-b0f8-0a580a800029@csi-snap-c45fabfc-de52-11eb-b0f8-0a580a800029: cannot create thin volume from thick volume "ocs-storagecluster-cephblockpool/csi-snap-c45fabfc-de52-11eb-b0f8-0a580a800029"


Error while creating a thick PVC from the snapshot of a RBD thin PVC:

Generated from openshift-storage.rbd.csi.ceph.com_csi-rbdplugin-provisioner-5f656cc8f7-t9z6l_2f55c1c2-b209-41fd-a91d-2e27956c7ace

failed to provision volume with StorageClass "ocs-storagecluster-ceph-rbd-thick": rpc error: code = InvalidArgument desc = cannot restore from snapshot ocs-storagecluster-cephblockpool/csi-vol-2cc20945-de55-11eb-b0f8-0a580a800029@csi-snap-31b3116a-de55-11eb-b0f8-0a580a800029: cannot create thick volume from thin volume "ocs-storagecluster-cephblockpool/csi-snap-31b3116a-de55-11eb-b0f8-0a580a800029"


Verified that switch between thin to thick and vice versa while restoring a snapshot is disabled.
The restored PVC will remain in pending status. A better approach will be not not attempt provision the volume instead of keeping the PVC in pending state. Considering the fact that the thick-thin and thin-thick switching will be enabled when the feature become fully supported, it is okay to keep this behavior in OCS 4.8.


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