Bug 2247657

Summary: Host assisted clone hangs because some provisioners don't allow mounting block PVC read only
Product: Container Native Virtualization (CNV) Reporter: Alex Kalenyuk <akalenyu>
Component: StorageAssignee: Alex Kalenyuk <akalenyu>
Status: CLOSED ERRATA QA Contact: dalia <dafrank>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.14.0CC: dafrank, hmeir
Target Milestone: ---   
Target Release: 4.14.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: CNV v4.14.1.rhel9-11 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2247666 2247667 (view as bug list) Environment:
Last Closed: 2023-12-07 15:02:20 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:
Bug Depends On:    
Bug Blocks: 2247666, 2247667    

Description Alex Kalenyuk 2023-11-02 15:41:41 UTC
Description of problem:
When attempting to Clone a Data volume across storage classes, the clone hangs indefinitely.
Source pods failing with
4h24m       Warning   FailedMapVolume   pod/3bc29af2-75a5-4b20-bd1e-42ce1e280c16-source-pod   MapVolume.MapPodDevice failed for volume "csivol-ec0afd0f5c" : rpc error: code = InvalidArgument desc = read only not supported for Block Volume 

Version-Release number of selected component (if applicable):
CNV 4.14.0

How reproducible:
100%

Steps to Reproduce:
1.
2.
3.

Actual results:
Host assisted clone does not work

Expected results:
Host assisted clone works in this scenario (max compatibility)

Additional info:

Comment 2 Harel Meir 2023-11-21 09:15:55 UTC
Verified on 4.14.1

steps:

1. create dv from ocs to block volumemode:
apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
  name: dv-source-ocs
spec:
  source:
      http:
         url: "http://cnv-qe-server.rhos-psi.cnv-qe.rhood.us/files/cnv-tests/cirros-images/cirros-0.4.0-x86_64-disk.qcow2"
  storage:
    resources:
      requests:
        storage: 1Gi
    storageClassName: ocs-storagecluster-ceph-rbd-virtualization

2. cloned the dv to hpp fs:
apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
  name: cloned-dv
  namespace: default
  annotations:
    cdi.kubevirt.io/storage.bind.immediate.requested: 'true'
spec:
  source:
    pvc:
      name: dv-source-ocs
      namespace: default
  storage:
    storageClassName: hostpath-csi-basic

3. Clone successful and pod didnt failed

Note: verified also for vice verse, fs -> block

Comment 9 errata-xmlrpc 2023-12-07 15:02:20 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 (Important: OpenShift Virtualization 4.14.1 security 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:7704