Bug 2107241 - [OCPonRHV] CSI provisioned disks are effectively preallocated due to go-ovirt-client setting Provisioned and Initial size of the disk to the same value
Summary: [OCPonRHV] CSI provisioned disks are effectively preallocated due to go-ovirt...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Storage
Version: 4.11
Hardware: x86_64
OS: Linux
high
high
Target Milestone: ---
: 4.12.0
Assignee: Veronika Fuxova
QA Contact: Veronika Fuxova
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-14 14:52 UTC by Veronika Fuxova
Modified: 2023-01-17 19:52 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-01-17 19:52:40 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github oVirt go-ovirt-client pull 229 0 None Merged FIX Bug 2107241: CSI provisioned disks are preallocated 2022-08-24 08:26:07 UTC
Github openshift ovirt-csi-driver pull 113 0 None Merged Bug 2107241: CSI provisioned disks are preallocated 2022-08-24 08:25:51 UTC
Red Hat Product Errata RHSA-2022:7399 0 None None None 2023-01-17 19:52:57 UTC

Description Veronika Fuxova 2022-07-14 14:52:36 UTC
When a thin provisioned COW format disk is created on OCP on RHV via CSI driver (a PVC - https://github.com/openshift/ovirt-csi-driver/blob/master/deploy/example/storage-claim.yaml - with for example requested storage 100 GB), the go-ovirt-client behaviour makes it so that the created disk has virtual size 100 GB and it's actual size is 110 GB. 

But this is thin provisioned disk, so the initial size of the disk should be default of the engine and then grow as needed, it shouldn't be this big. 

This causes all the disks created this way to be functionally preallocated (since it eats all that space), which is a real waste of space. 

How reproducible: 100%

Steps to Reproduce:
1. Create a storage claim (PVC) in Openshift (https://github.com/openshift/ovirt-csi-driver/blob/master/deploy/example/storage-claim.yaml) using the default storage class (or any other storage class with thinProvisioning: "true") and with requested storage i.e. 100Gi

$ oc create -f storage-claim.yaml

2. In the RHV web console navigate to Storage -> Disks and check Virtual size and Actual size of the created disk (PVC) 

Actual results:
Disk from our example with requested storage 100GB reports virtual size 100GB and actual size 110 GB. 

Expected results:
Thin provisioned disks should start with small initial size and then grow as needed, so its actual size should be considerably smaller (the default initial size set by the engine should be 2.5 GB if I'm not mistaken). 

Note: The extra 10GB in the actual size are caused by overhead for the qcow2 disk format, which is 10%, and this was tracked here as a separate issue: 

https://bugzilla.redhat.com/show_bug.cgi?id=2097139

Comment 1 Veronika Fuxova 2022-08-22 13:41:17 UTC
Verified on: 
OCP 4.12.0-0.nightly-2022-08-21-205113 
RHV 4.4 SP1 [ovirt-engine-4.5.2.1-0.1.el8ev]

Comment 4 errata-xmlrpc 2023-01-17 19:52:40 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: OpenShift Container Platform 4.12.0 bug fix and security 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-2022:7399


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