Bug 1247144 - Can't update storage domain via REST API in case that the storage domain's 'containsUnregisteredEntities' property is true
Summary: Can't update storage domain via REST API in case that the storage domain's 'c...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: oVirt
Classification: Retired
Component: ovirt-engine-core
Version: 3.5
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 3.5.5
Assignee: Idan Shaby
QA Contact: Aharon Canan
URL:
Whiteboard: storage
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-27 12:27 UTC by Idan Shaby
Modified: 2016-02-10 18:22 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-11-09 12:00:13 UTC
oVirt Team: Storage
Embargoed:
amureini: ovirt_requires_release_note-


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 44024 0 master MERGED core: move containsUnregisteredEntities to StorageDomainDynamic Never
oVirt gerrit 44140 0 ovirt-engine-3.5 MERGED core: move containsUnregisteredEntities to StorageDomainDynamic Never

Description Idan Shaby 2015-07-27 12:27:33 UTC
Description of problem:
In case that the property 'containsUnregisteredEntities' of a storage domain is true, one cannot update any field of the domain via the rest api.

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

How reproducible:
100%

Steps to Reproduce:
1. Detach a storage domain that contains a vm disk from the dc (that will set 'containsUnregisteredEntities' to true).
2. Attach it to the dc.
3. Try to update any updatable property of this domain via the REST API. For example, its name:
http://localhost:8080/api/storagedomains/<sd_id>
<storage_domain>
<name>sd_new</name>
</storage_domain>

Actual results:
Error code 400.
The message is:
Cannot edit Storage. Can only update the following fields: name, description, comment, wipe after delete, low space threshold, and critical space threshold.

Expected results:
One should be able to update the storage domain via the REST API.

Additional info:

Comment 1 Allon Mureinik 2015-07-27 12:32:18 UTC
This existed since 3.5.0. Proposing it for 3.5.5, but we need Aharon and Yaniv's input.

Comment 2 Allon Mureinik 2015-07-28 13:18:30 UTC
Patch was merged to master.
Idan - please backport to the ovirt-engine-3.5 branch.

Comment 3 Aharon Canan 2015-10-06 12:41:49 UTC
Verified using the following versions:
---------------------------------------
rhevm-3.5.5-0.1.el6ev.noarch - running on Rhel6.7
vdsm-4.16.27-1.el7ev.x86_64 - running on Rhel7.1

1. VM with disk on SD1
2. detach SD1
3. attach SD1 again to the DC
4. try to set new SD name 

<storage_domain>
<name>sd_new</name>
</storage_domain>

works fine


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