Bug 853712

Summary: ovirt-engine-backend [Quota]: after editing quota on a disk I can no longer change the quota back with CanDoAction
Product: Red Hat Enterprise Virtualization Manager Reporter: Dafna Ron <dron>
Component: ovirt-engineAssignee: Gilad Chaplik <gchaplik>
Status: CLOSED CURRENTRELEASE QA Contact: Dafna Ron <dron>
Severity: high Docs Contact:
Priority: high    
Version: 3.1.0CC: acathrow, dfediuck, dyasny, hateya, iheim, lpeer, Rhev-m-bugs, yeylon, ykaul
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: sla
Fixed In Version: si17 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: SLA RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
log none

Description Dafna Ron 2012-09-02 11:02:16 UTC
Created attachment 609048 [details]
log

Description of problem:

i have two quota's on the same storage. 
after editing the disk and changing Quota1 to Quota2 I tried to edit the disk again and change the Quota2 back to Quota1 and got a CanDoAction: 

012-09-02 13:51:46,538 WARN  [org.ovirt.engine.core.bll.UpdateVmDiskCommand] (ajp-/127.0.0.1:8009-6) CanDoAction of action UpdateVmDisk failed. Reasons:VAR__ACTION__UPDATE,VAR__TYPE__VM_DISK,ACTION_TYPE_FAILED_QUOTA_STORAGE_LIMIT_EXCEEDED

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

SI16

How reproducible:

100%

Steps to Reproduce:
1. create a quota and a vm with disk
2. create a second quota on the same domain 
3. edit disk and change Quota1 to Quota2
4. try to change Quota2 back to Quota1
  
Actual results:

we fail with CanDoAction: 

012-09-02 13:51:46,538 WARN  [org.ovirt.engine.core.bll.UpdateVmDiskCommand] (ajp-/127.0.0.1:8009-6) CanDoAction of action UpdateVmDisk failed. Reasons:VAR__ACTION__UPDATE,VAR__TYPE__VM_DISK,ACTION_TYPE_FAILED_QUOTA_STORAGE_LIMIT_EXCEEDED

Expected results:

we should succeed to change the quota

Additional info: backend log

Comment 1 Dafna Ron 2012-09-02 11:12:39 UTC
same thing will happen with the assign quota from the disk tab

Comment 3 Dafna Ron 2012-09-02 12:15:15 UTC
I have 3 iscsi domains 50GB each. 
quota is enforced
1) I create a quota1 with 30GB on each of the domains (in quota -> specific domain -> 30GB on each). 
2) I created a VM with one disk on 1 domain
3) I created quota2 which is unlimited 
4) edit/assign quota -> change quota1 to quota2
5) edit/assign quota -> change quota2 back to quota1

we get an error

Comment 6 Dafna Ron 2012-09-09 14:30:51 UTC
verified on si17