Bug 2241658 - Wrong error message when attempting to upload an image to a PVC that already has disk.img
Summary: Wrong error message when attempting to upload an image to a PVC that already ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Storage
Version: 4.14.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.14.1
Assignee: Álvaro Romero
QA Contact: Jenia Peimer
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-10-01 19:20 UTC by Jenia Peimer
Modified: 2024-02-19 07:29 UTC (History)
3 users (show)

Fixed In Version: v4.14.1.rhel9-22
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-12-07 15:00:47 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt kubevirt pull 10534 0 None Merged Improve error handling when attempting to upload an already succeeded DataVolume 2023-11-05 10:44:22 UTC
Github kubevirt kubevirt pull 10634 0 None Merged Improve image-upload condition to know if population succeeded 2023-11-02 12:38:51 UTC
Red Hat Issue Tracker CNV-33621 0 None None None 2023-10-01 19:21:28 UTC
Red Hat Product Errata RHSA-2023:7704 0 None None None 2023-12-07 15:00:48 UTC

Description Jenia Peimer 2023-10-01 19:20:57 UTC
Description of problem:
Wrong error message when attempting to upload an image to a PVC that already has disk.img

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

How reproducible:
Always, starting from CNV-v4.14.0.rhel9-1959 (maybe earlier, we only know it worked in the build 1905)

Steps to Reproduce:
1. Upload an image with virtctl - completed successfully / (or import a DV/PVC)

$ virtctl image-upload dv cnv-3729 --image-path=./cirros-0.4.0-x86_64-disk.qcow2 --size=1Gi --storage-class=ocs-storagecluster-ceph-rbd-virtualization --access-mode=ReadWriteMany --insecure --block-volume

2. Run 'virtctl image-upload' command attempting to upload an image to the same PVC

3. See the result:
Unable to get PVC Prime default/cnv-3729

Actual results:
'Unable to get PVC Prime default/cnv-3729'

Expected results:
'PVC cnv-3729 already successfully imported/cloned/updated'

Additional info:
This change happened in the recent builds:
CNV-v4.14.0.rhel9-1905 - Passed (Sep 10)
CNV-v4.14.0.rhel9-1959 - Failed (Sep 16)

Comment 3 Álvaro Romero 2023-11-16 14:02:11 UTC
Still waiting for a somewhat related PR to be merged (https://github.com/kubevirt/containerized-data-importer/pull/2964) but this behavior should already be fixed.

Comment 4 Harel Meir 2023-11-26 14:18:19 UTC
Hi, Im getting this error msg on 4.14 & 4.15:
PVC cnv-3729-hostpath-csi-basic already successfully populated

When running:

virtctl -n cdi-upload-test-upload-virtctl --kubeconfig /tmp/tmpk53zwwus-cnv-tests-kubeconfig/kubeconfig image-upload dv cnv-3729-hostpath-csi-basic --image-path=/tmp/cirros-qcow2.img --size=1Gi --storage-class=hostpath-csi-basic --access-mode=ReadWriteOnce --insecure --no-create


It also happens with ocs,hostpath.

With NFS tho, it producing the correct error message:
PVC cnv-3729 already successfully imported/cloned/updated

Comment 5 Jenia Peimer 2023-11-26 14:34:06 UTC
It looks okay, because our nfs is not a csi storage, so CDI uses the pre-populators flow. But the message is clear in both ways.
We just need to update our tests now.

Thanks Harel for checking,
Thanks Alvaro for fixing!

Comment 6 Jenia Peimer 2023-11-27 10:18:47 UTC
Verified based on Harel's comment.

Comment 14 errata-xmlrpc 2023-12-07 15:00:47 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


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