From 852cf3bca7e4bf768f9c3e478e5b1e919df57977 Mon Sep 17 00:00:00 2001 From: Lars Kellogg-Stedman Date: Fri, 27 Apr 2018 22:43:35 -0400 Subject: [PATCH] log stale allocations as WARNING instead of DEBUG Stale resource allocations can prevent Nova from scheduling new instances on a host that otherwise has sufficient resources available. Nova would log a message about this situation on the affected compute node, but it was logged at DEBUG priority and so would typically not be visible in a production environment. This commit modifies Nova to log the message as a warning instead. Change-Id: I347d2ab0077c4d9b62bc169af9e039d00ec214fa Closes-bug: #1767553 (cherry picked from commit a54e5ed00f98b8536080647e5caa90d556d6e809) (cherry picked from commit 12a3b698d17672ec0277dff4e96c44a92186aab1) --- nova/compute/resource_tracker.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/nova/compute/resource_tracker.py b/nova/compute/resource_tracker.py index 7caa64b70f3f..d9108608da0b 100644 --- a/nova/compute/resource_tracker.py +++ b/nova/compute/resource_tracker.py @@ -1278,12 +1278,13 @@ class ResourceTracker(object): # that contains this source compute host information anyway and # recreate an allocation that only refers to itself. So we # don't need to do anything in that case. Just log the - # situation here for debugging information but don't attempt to - # delete or change the allocation. - LOG.debug("Instance %s has been moved to another host %s(%s). " - "There are allocations remaining against the source " - "host that might need to be removed: %s.", - instance_uuid, instance.host, instance.node, alloc) + # situation here for information but don't attempt to delete or + # change the allocation. + LOG.warning("Instance %s has been moved to another host " + "%s(%s). There are allocations remaining against " + "the source host that might need to be removed: " + "%s.", + instance_uuid, instance.host, instance.node, alloc) def delete_allocation_for_evacuated_instance(self, instance, node, node_type='source'):