commit 643405b3a751f7547417e48e00db05d9fe8e99c4
Author: Sean Mooney <email address hidden>
Date: Thu Oct 10 18:00:07 2019 +0100
Block rebuild when NUMA topology changed
If the image change during a rebuild it's possible for the request
NUMA topology to change. As a rebuild uses a noop claim in the
resource tracker the NUMA topology will not be updated as part of
a rebuild.
If the NUMA constraints do not change, a rebuild will continue as normal.
If the new constraints conflict with the existing NUMA constraints of the
instance the rebuild will be rejected without altering the status of the
instance.
This change introduces an API check to block rebuild when the NUMA
requirements for the new image do not match the existing NUMA constraints.
This is in line with the previous check introduced to prevent the rebuild of
volume-backed instances which similarly are not supported.
This change adds functional tests to assert the expected behaviour of
rebuilding NUMA instances with new images. This change also asserts that
in place rebuilds of numa instances is currently not supported.
NOTE(sean-k-mooney): Due to the lack of changes
I3b4c1153bebdeab2eb8bc2108aa177732f5c6a97 and
I06fad233006c7bab14749a51ffa226c3801f951b,
nova/api/openstack/compute/servers.py was modified to
add exception handling for the 'ImageNUMATopologyRebuildConflict'
on rebuild and 'nova/tests/functional/libvirt/test_numa_servers.py'
was modified to mock the libvirt connection in the
'NUMAServersRebuildTests.setUp' function.
Due to a lack of I34ffaf285718059b55f90e812b57f1e11d566c6f
'nova/tests/unit/api/openstack/compute/test_server_actions.py' and
'nova/tests/unit/compute/test_compute.py' were updated to use valid
image UUIDs.
Closes-Bug: #1763766
Partial-implements: blueprint inplace-rebuild-of-numa-instances
Change-Id: I0322d872bdff68936033a6f5a54e8296a6fb3434
(cherry picked from commit 6f5358ac1992b17b7f3f99d9a32290e0d4740dae)
(cherry picked from commit 745de99063bf77704a7f0610fe9e3647257eaa50)
(cherry picked from commit 9f57d16f38f0290718e3ba78393d064746f7e527)
Reviewed: https:/ /review. opendev. org/703116 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=643405b3a75 1f7547417e48e00 db05d9fe8e99c4
Committed: https:/
Submitter: Zuul
Branch: stable/rocky
commit 643405b3a751f75 47417e48e00db05 d9fe8e99c4
Author: Sean Mooney <email address hidden>
Date: Thu Oct 10 18:00:07 2019 +0100
Block rebuild when NUMA topology changed
If the image change during a rebuild it's possible for the request
NUMA topology to change. As a rebuild uses a noop claim in the
resource tracker the NUMA topology will not be updated as part of
a rebuild.
If the NUMA constraints do not change, a rebuild will continue as normal.
If the new constraints conflict with the existing NUMA constraints of the
instance the rebuild will be rejected without altering the status of the
instance.
This change introduces an API check to block rebuild when the NUMA
requirements for the new image do not match the existing NUMA constraints.
This is in line with the previous check introduced to prevent the rebuild of
volume-backed instances which similarly are not supported.
This change adds functional tests to assert the expected behaviour of
rebuilding NUMA instances with new images. This change also asserts that
in place rebuilds of numa instances is currently not supported.
Conflicts:
nova/api/ openstack/ compute/ servers. py
nova/tests/ functional/ integrated_ helpers. py
nova/tests/ functional/ libvirt/ test_numa_ servers. py
nova/tests/ unit/compute/ test_compute_ api.py
Modified:
nova/tests/ unit/api/ openstack/ compute/ test_server_ actions. py
nova/tests/ unit/compute/ test_compute. py
NOTE( sean-k- mooney) : Due to the lack of changes bdeab2eb8bc2108 aa177732f5c6a97 and 6c7bab14749a51f fa226c3801f951b , api/openstack/ compute/ servers. py was modified to ogyRebuildConfl ict' functional/ libvirt/ test_numa_ servers. py' sRebuildTests. setUp' function. 9b55f90e812b57f 1e11d566c6f tests/unit/ api/openstack/ compute/ test_server_ actions. py' and tests/unit/ compute/ test_compute. py' were updated to use valid
I3b4c1153be
I06fad23300
nova/
add exception handling for the 'ImageNUMATopol
on rebuild and 'nova/tests/
was modified to mock the libvirt connection in the
'NUMAServer
Due to a lack of I34ffaf28571805
'nova/
'nova/
image UUIDs.
Closes-Bug: #1763766 implements: blueprint inplace- rebuild- of-numa- instances 936033a6f5a54e8 296a6fb3434 b7f3f99d9a32290 e0d4740dae) 04a7f0610fe9e36 47257eaa50) 718e3ba78393d06 4746f7e527)
Partial-
Change-Id: I0322d872bdff68
(cherry picked from commit 6f5358ac1992b17
(cherry picked from commit 745de99063bf777
(cherry picked from commit 9f57d16f38f0290