nova-compute resource tracker ignores 'reserved' while reporting 'max_unit'
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Won't Fix
|
Low
|
Unassigned |
Bug Description
The following inventory was reported after a fresh devstack build:
curl --silent \
--header "Accept: application/json" \
--header "Content-Type: application/json" \
--header "OpenStack-
--header "X-Auth-Token: ${TOKEN:?}" \
-X GET http://
{
"resource_
"inventories" : {
"DISK_GB" : {
"max_unit" : 19,
"min_unit" : 1,
"reserved" : 0,
"total" : 19
},
"MEMORY_MB" : {
"max_unit" : 5967,
"min_unit" : 1,
"reserved" : 512,
"total" : 5967
},
"VCPU" : {
"min_unit" : 1,
"max_unit" : 2,
"reserved" : 0,
"total" : 2
}
}
}
IMO the correct max_unit value of the MEMORY_MB resource would be (total - reserved). But today it equals the total value.
nova commit: 9e9b3e1
devstack commit: fbdefac
devstack config: ENABLED_
description: | updated |
That could be understandable that max_unit should be limited to what you can actually consume, so I tend to agree with you, but fixing that would imply two things :
- it would be a huge upgrade problem, because every compute would now need to modify its inventory
- we would have a dependency between max_unit and reserved, which I feel shouldn't
For that reason, since we already verify the reserved space, I think it's just something like a detail that wouldn't need to be modified.