summaryrefslogtreecommitdiff
path: root/nova/scheduler
diff options
context:
space:
mode:
authorSean Mooney <work@seanmooney.info>2019-10-21 16:17:17 +0000
committerSean Mooney <work@seanmooney.info>2019-12-09 18:07:12 +0000
commit3f9411071d4c1a04ab0b68fd635597bf6959c0ca (patch)
tree9e3815731ad3ef6eb81673393d7c909a88128e81 /nova/scheduler
parent6f5358ac1992b17b7f3f99d9a32290e0d4740dae (diff)
downloadnova-3f9411071d4c1a04ab0b68fd635597bf6959c0ca.tar.gz
Disable NUMATopologyFilter on rebuild
This change leverages the new NUMA constraint checking added in in I0322d872bdff68936033a6f5a54e8296a6fb3434 to allow the NUMATopologyFilter to be skipped on rebuild. As the new behavior of rebuild enfroces that no changes to the numa constraints are allowed on rebuild we no longer need to execute the NUMATopologyFilter. Previously the NUMATopologyFilter would process the rebuild request as if it was a request to spawn a new instnace as the numa_fit_instance_to_host function is not rebuild aware. As such prior to this change a rebuild would only succeed if a host had enough additional capacity for a second instance on the same host meeting the requirement of the new image and existing flavor. This behavior was incorrect on two counts as a rebuild uses a noop claim. First the resouce usage cannot change so it was incorrect to require the addtional capacity to rebuild an instance. Secondly it was incorrect not to assert the resouce usage remained the same. I0322d872bdff68936033a6f5a54e8296a6fb3434 adressed guarding the rebuild against altering the resouce usage and this change allows in place rebuild. This change found a latent bug that will be adressed in a follow up change and updated the functional tests to note the incorrect behavior. Change-Id: I48bccc4b9adcac3c7a3e42769c11fdeb8f6fd132 Closes-Bug: #1804502 Implements: blueprint inplace-rebuild-of-numa-instances
Diffstat (limited to 'nova/scheduler')
-rw-r--r--nova/scheduler/filters/numa_topology_filter.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/nova/scheduler/filters/numa_topology_filter.py b/nova/scheduler/filters/numa_topology_filter.py
index 9b90363718..fae8a45600 100644
--- a/nova/scheduler/filters/numa_topology_filter.py
+++ b/nova/scheduler/filters/numa_topology_filter.py
@@ -23,7 +23,11 @@ LOG = logging.getLogger(__name__)
class NUMATopologyFilter(filters.BaseHostFilter):
"""Filter on requested NUMA topology."""
- RUN_ON_REBUILD = True
+ # NOTE(sean-k-mooney): In change I0322d872bdff68936033a6f5a54e8296a6fb343
+ # we validate that the NUMA topology does not change in the api. If the
+ # requested image would alter the NUMA constrains we reject the rebuild
+ # request and therefore do not need to run this filter on rebuild.
+ RUN_ON_REBUILD = False
def _satisfies_cpu_policy(self, host_state, extra_specs, image_props):
"""Check that the host_state provided satisfies any available