Bug 2221461 - virtctl image-upload fails for WFFC storage with Populators
Summary: virtctl image-upload fails for WFFC storage with Populators
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Storage
Version: 4.14.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.14.0
Assignee: skagan
QA Contact: Jenia Peimer
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-07-09 08:10 UTC by Jenia Peimer
Modified: 2023-11-08 14:06 UTC (History)
2 users (show)

Fixed In Version: CNV v4.14.0.rhel9-1259
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-08 14:05:53 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt containerized-data-importer pull 2765 0 None Merged Allow ImmediateBinding annotation when using populators 2023-07-11 07:46:03 UTC
Github kubevirt kubevirt pull 10065 0 None Merged Handle image-upload with new populators phase 2023-07-11 08:42:35 UTC
Github kubevirt kubevirt pull 10072 0 None Merged [release-1.0] Handle image-upload with new populators phase 2023-07-12 07:57:57 UTC
Red Hat Issue Tracker CNV-30793 0 None None None 2023-07-09 08:12:52 UTC
Red Hat Product Errata RHSA-2023:6817 0 None None None 2023-11-08 14:06:02 UTC

Description Jenia Peimer 2023-07-09 08:10:14 UTC
Description of problem:

virtctl image-upload fails for WFFC storage:
  with --force-bind - should upload successfully
  without --force-bind - should report a proper error

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

How reproducible:
Always

Steps to Reproduce:

1. With --force-bind flag:

   $ virtctl image-upload dv cirros-dv-force-bind --image-path=./cirros-0.4.0-x86_64-disk.qcow2  --size=1Gi --storage-class=hostpath-csi-basic --insecure --force-bind
   PVC default/cirros-dv-force-bind not found
   DataVolume default/cirros-dv-force-bind created
   Waiting for PVC cirros-dv-force-bind upload pod to be ready...
   <GETS STUCK HERE FOR SOME TIME> 
   timed out waiting for the condition

   $ oc get dv 
   NAME                   PHASE               PROGRESS   RESTARTS   AGE
   cirros-dv-force-bind   PendingPopulation   N/A                   12m

   $ oc get dv cirros-dv-force-bind -oyaml
     apiVersion: cdi.kubevirt.io/v1beta1  
     kind: DataVolume
     metadata:
       annotations:
         cdi.kubevirt.io/storage.bind.immediate.requested: ""
         cdi.kubevirt.io/storage.usePopulator: "true"


2. Without --force-bind flag: 

   $ virtctl image-upload dv cirros-dv --image-path=./cirros-0.4.0-x86_64-disk.qcow2  --size=1Gi --storage-class=hostpath-csi-basic --insecure 
   PVC default/cirros-dv not found 
   DataVolume default/cirros-dv 
   created Waiting for PVC cirros-dv upload pod to be ready... 
   <GETS STUCK HERE FOR SOME TIME> 
   timed out waiting for the condition

   $ oc get dv 
   NAME                   PHASE               PROGRESS   RESTARTS   AGE
   cirros-dv              PendingPopulation   N/A                   13m

   $ oc get dv cirros-dv -oyaml
   apiVersion: cdi.kubevirt.io/v1beta1
   kind: DataVolume
   metadata:
     annotations:
       cdi.kubevirt.io/storage.usePopulator: "true"


Expected results:

virtctl image-upload with --force-bind flag - uploaded successfully
virtctl image-upload without --force-bind flag - reported a proper error

Comment 1 Jenia Peimer 2023-07-17 14:13:28 UTC
Verified on CNV v4.14.0.rhel9-1259

CDI version: 
$ oc exec $(oc get pod -n openshift-cnv -l=cdi.kubevirt.io=cdi-apiserver --output=jsonpath='{$.items[0].metadata.name}') --namespace=openshift-cnv -- virt-cdi-apiserver --version
Containerized Data Importer v1.57.0-rc1-2-g5a387edf5


With --force-bind:

$ virtctl image-upload dv cirros-dv-force-bind --image-path=./cirros-0.4.0-x86_64-disk.qcow2  --size=1Gi --storage-class=hostpath-csi-basic --insecure --force-bind
PVC default/cirros-dv-force-bind not found 
DataVolume default/cirros-dv-force-bind created
Waiting for PVC cirros-dv-force-bind upload pod to be ready...
Pod now ready
Uploading data to https://cdi-uploadproxy-openshift-cnv.apps.c01-jp414.<link>.com

 12.13 MiB / 12.13 MiB [======================================================================================================] 100.00% 0s

Uploading data completed successfully, waiting for processing to complete, you can hit ctrl-c without interrupting the progress
Processing completed successfully
Uploading ./cirros-0.4.0-x86_64-disk.qcow2 completed successfully



Without --force-bind:

$ virtctl image-upload dv cirros-dv --image-path=./cirros-0.4.0-x86_64-disk.qcow2  --size=1Gi --storage-class=hostpath-csi-basic --insecure 
PVC default/cirros-dv not found 
DataVolume default/cirros-dv created
Waiting for PVC cirros-dv upload pod to be ready...
cannot upload to DataVolume in PendingPopulation phase, make sure the PVC is Bound, or use force-bind flag

Comment 3 errata-xmlrpc 2023-11-08 14:05:53 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.0 Images 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:6817


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