Correct VIM host audit criteria for failing instances

The VIM's host audit will fail instances on any host that is
"not enabled". That includes hosts where the operational state
is unknown.

Updating the check to ensure the host is "disabled" not that it
is "not enabled" to avoid failing instances on a host where we
don't know the operational state.

Change-Id: I68d3e9f63695de721c10fb1dd2b7ac5917cb50fa
Closes-Bug: 1840176
Signed-off-by: Bart Wensley <barton.wensley@windriver.com>
This commit is contained in:
Bart Wensley 2019-08-15 07:41:01 -05:00
parent 4d6ff3de71
commit f98b388a74
1 changed files with 1 additions and 1 deletions

View File

@ -1467,7 +1467,7 @@ class InstanceDirector(object):
host.name))
return
if not host.nfvi_host_is_enabled() or host.is_failed() or host.is_offline():
if host.is_disabled() or host.is_failed() or host.is_offline():
instance_table = tables.tables_get_instance_table()
for instance in instance_table.on_host(host.name):
if instance.is_deleting() or instance.is_deleted() or \