Description of problem: The target disk's actual size after the disk allocation policy convert is the same as before the convert action. Version-Release number of selected component (if applicable): Engine-4.5.0.7-0.9.el8ev vdsm-4.50.0.13-1.el8ev How reproducible: 100% Steps to Reproduce: 1. Create an empty 5G disk cow+preallocated 2. Convert the disk to cow+Thin(sparse) 3. Check the actual_size of the disk Actual results: The actual size of the disk is 5G, identical to its' provisioned size before the convert. Expected results: The actual size of the disk after the convert should be smaller than 5G (according to the defaults it should be 2.5G) Additional info: The convert succeeds and it actually changes the allocation policy when checking in the DB of the disk, but the actual size which is the main functionality of the convert allocation policy does meet the expectations
Fixing Engine version I tested this on: Engine-4.5.0.6-0.7.el8ev
While verifying I've found that the actual size after the convert is now 134217728, which is much less than the 2.5G default size for the thin disk. Is it fine, or something is wrong? For example I converted ISCSI-Cow-Preallocated-Enabled to ISCSI-Cow-Thin-Enabled and got this: <backup>incremental</backup> <content_type>data</content_type> <format>cow</format> ... <propagate_errors>false</propagate_errors> <provisioned_size>5368709120</provisioned_size> <shareable>false</shareable> <sparse>true</sparse> <status>ok</status> <storage_type>image</storage_type> <total_size>134217728</total_size>
As discussed, the actual allocated size is 134217728, so that is the required size for the conversion to qcow, as measure by: $ qemu-img measure -f qcow2 -O qcow2 img
Verified. The actual size of the disk after conversion is 134217728, which is smaller than 5G. Versions: engine-4.5.1.3-654.af4ac851f145.35.el8ev vdsm-4.50.2-1.el8ev.x86_64
This bugzilla is included in oVirt 4.5.2 release, published on August 10th 2022. Since the problem described in this bug report should be resolved in oVirt 4.5.2 release, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report.