Bug 2081559

Summary: [RFE] discrepancy tool should detect preallocated cow images that were reduced
Product: Red Hat Enterprise Virtualization Manager Reporter: Germano Veit Michel <gveitmic>
Component: rhv-log-collector-analyzerAssignee: Germano Veit Michel <gveitmic>
Status: CLOSED ERRATA QA Contact: Barbora Dolezalova <bdolezal>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.4.10CC: aperotti, apinnick, gdeolive
Target Milestone: ovirt-4.5.1Keywords: FieldEngineering, FutureFeature, ZStream
Target Release: 4.5.1   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: rhv-log-collector-analyzer-1.0.14-1.el8ev Doc Type: Enhancement
Doc Text:
The rhv-log-collector-analyzer discrepancy tool now detects preallocated QCOW2 images that have been reduced.
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-07-14 12:54:34 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Integration RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Germano Veit Michel 2022-05-04 00:51:37 UTC
This is to track an improvement to be able to detect BZ2081493.

We want to highlight this case:
* the volume size in the storage is lower than the capacity
* the volume is QCOW2 (optional?)
* the volume is preallocated

So that the tool will complain on disks that are supposed to be preallocated but are not.

Comment 3 Germano Veit Michel 2022-05-13 00:41:03 UTC
For QE:

1. Create a VM, with no disks
2. Virtual Machines -> VM -> Disks -> New
   Set the disk to preallocated and enable incremental:
     Allocation Policy: PREALLOCATED
     [x] Enable Incremental Backup
     Size: 100G
3. Click OK
5. Create a snapshot of the VM
6. Delete that snapshot.

While using an engine/vdsm without fix for BZ 2081493, the tool should print this message for the disk created in step 2.

$ rhv-image-discrepancies 
~~~
Image image_guid size on the storage(1073741824) is smaller than capacity(107374182400), but type is preallocated
~~~

Comment 7 Barbora Dolezalova 2022-06-13 12:14:58 UTC
I followed the steps and the tool printed the message:
Image image_guid size on the storage(200704) is smaller than capacity(107374182400), but type is preallocated.

Verified in rhv-log-collector-analyzer-1.0.14-1.el8ev.noarch, ovirt-engine-4.5.1-0.62.el8ev.noarch

Comment 12 errata-xmlrpc 2022-07-14 12:54:34 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: RHV Manager (ovirt-engine) [ovirt-4.5.1] security, bug fix and 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:5555