If the compute service is restarted while build requests are
executing the instance_claim or waiting for the COMPUTE_RESOURCE_SEMAPHORE
then those instances will be stuck forever in BUILDING state. If the instance
already finished instance_claim then instance.host is set and when the
compute restarts the instance is put to ERROR state.
This patch changes compute service startup to put instances into
ERROR state if they a) are in the BUILDING state, and b) have
allocations on the compute resource provider, but c) do not have
instance.host set to that compute.
Reviewed: https:/ /review. opendev. org/687565 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=13bb7ed7011 21955ba015103c2 e44429927e78d4
Committed: https:/
Submitter: Zuul
Branch: stable/rocky
commit 13bb7ed70112195 5ba015103c2e444 29927e78d4
Author: Balazs Gibizer <email address hidden>
Date: Fri Jun 21 16:48:14 2019 +0200
Error out interrupted builds
If the compute service is restarted while build requests are RESOURCE_ SEMAPHORE
executing the instance_claim or waiting for the COMPUTE_
then those instances will be stuck forever in BUILDING state. If the instance
already finished instance_claim then instance.host is set and when the
compute restarts the instance is put to ERROR state.
This patch changes compute service startup to put instances into
ERROR state if they a) are in the BUILDING state, and b) have
allocations on the compute resource provider, but c) do not have
instance.host set to that compute.
Conflicts:
nova/ tests/unit/ compute/ test_compute_ mgr.py
nova/ compute/ manager. py
Conflict due to Ia1b3ab0b66fdaf 569f6c7a09510f2 08ee28725b2 and fc79f8907b7bfb7 53ec779a8da69a1 is not in stable/rocky
I020e7dc47e
Change-Id: I856a3032c83fc2 f605d8c9b6e5aa3 bcfa415f96a 8277c9fc5339f3b 74f968b58e) d7bf7d52bc9062e ecba8d7d27) e04a063cd7b5ae2 e83ddfe6dd)
Closes-Bug: #1833581
(cherry picked from commit a1a735bc6efa40d
(cherry picked from commit 06fd7c730172190
(cherry picked from commit cb951cbcb246221