placement allows RP parent loop in PUT resource_providers/{uuid}
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Medium
|
Balazs Gibizer |
Bug Description
Placement allows setting the parent_rp_uuid of an RP to itself. This leads to a trivial loop in the RP tree.
Version, current master:
stack@ubuntu:
4ea64ca Merge "manage: Remove dead code"
To reproduce in devstack I used a not yet merged osc-placement patch adding support to api version 1.14.
Steps:
stack@ubuntu:
+------
| uuid | name | generation | root_provider_uuid | parent_
+------
| f4d95373-
+------
stack@ubuntu:
+------
| Field | Value |
+------
| uuid | f4d95373-
| name | ubuntu |
| generation | 1 |
| root_provider_uuid | f4d95373-
| parent_
+------
stack@ubuntu:
+------
| uuid | name | generation | root_provider_uuid | parent_
+------
| f4d95373-
+------
Full debug output with has been attached.
Changed in nova: | |
status: | New → Confirmed |
importance: | Undecided → Medium |
If I try to create the loop at RP creation the placement rejects the request properly ~/nova$ openstack resource provider create --os-placement- api-version 1.14 my-rp2 --uuid 711b5af9- 3924-4047- b08d-14ca6a4c75 39 --parent- provider- uuid 711b5af9- 3924-4047- b08d-14ca6a4c75 39 3924-4047- b08d-14ca6a4c75 39: Object action create failed because: parent provider UUID cannot be same as UUID. Please set parent provider UUID to None if there is no parent. (HTTP 400)
stack@ubuntu:
Unable to create resource provider "my-rp2", 711b5af9-