Bug 1872602

Summary: Incorrect storage consumption on Quota list page
Product: [oVirt] ovirt-engine Reporter: Lucia Jelinkova <ljelinko>
Component: BLL.StorageAssignee: Lucia Jelinkova <ljelinko>
Status: CLOSED CURRENTRELEASE QA Contact: Qin Yuan <qiyuan>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 4.4.1CC: ahadas, bugs, tnisan
Target Milestone: ovirt-4.4.3Flags: pm-rhel: ovirt-4.4+
Target Release: 4.4.3.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ovirt-engine-4.4.3.1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-11-11 06:42:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Virt RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Lucia Jelinkova 2020-08-26 07:43:52 UTC
Description of problem:

When copying disk with quota fails, the calculated quota is not rolled back and as a result, the quota cache contains incorrect value. This value is displayed in Quota list page.

Steps to Reproduce:
1.Create a new quota and add it to a disk with size > 0
2.Check Storage consumption value in Quota list page
3.Copy the disk and make sure it fails
4.Check Storage consumption value in Quota list page

Actual results:
The Storage consumption value was increased by the size of the disk even though the copy disk operation failed and the disk was not created

Expected results:
The Storage consumption value should not be chagned

Comment 1 Qin Yuan 2020-09-10 11:49:12 UTC
Verified with:
ovirt-engine-4.4.3.1-0.7.el8ev.noarch

Steps:
1. Create a new quota and add it to a disk with size=50G
2. Check Storage consumption value in Quota list page
3. Copy the disk from domain1 to domain2, and disconnect domain2 during copy to make copy fail.
4. Check Storage consumption value in Quota list page

Results:
1. The storage consumption is 50G before copy disk
2. The storage consumption is 100G when copy disk start
3. The storage consumption return back to 50G when copy disk fails.

engine log:
2020-09-10 13:48:40,741+03 INFO  [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedThreadFactory-engine-Thread-295) [9c8551ec-f26e-4789-b346-51f4c7974438] EVENT_ID: USER_COPIED_DISK(2,004), User admin@internal-authz is copying disk testvm_Disk1 to domain test_mydomain.
2020-09-10 13:56:33,855+03 ERROR [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (EE-ManagedScheduledExecutorService-engineScheduledThreadPool-Thread-88) [] EVENT_ID: USER_COPIED_DISK_FINISHED_FAILURE(2,007), User admin@internal-authz finished with error copying disk testvm_Disk1 to domain test_mydomain.

Comment 2 Sandro Bonazzola 2020-11-11 06:42:22 UTC
This bugzilla is included in oVirt 4.4.3 release, published on November 10th 2020.

Since the problem described in this bug report should be resolved in oVirt 4.4.3 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.