Do not apply NoExecute taint to hosts

The VIM is currently appying the NoExecute taint to controller
and compute hosts when they are disabled, in order to cause
the pods on those hosts to be evicted. This is causing
problems when configuring a non-AIO system because the
VIM goes through disable/enable cycles while the pods are
coming up on these hosts. This causes the NoExecute taint
to be applied/removed and prevents the OpenStack pods from
ever coming up successfully.

For now, the VIM will not apply the NoExecute taint. We will
revisit this later.

Change-Id: Icc8cece900c69b8d2620023a00ac906359d59d84
Story: 2003910
Task: 26796
Signed-off-by: Bart Wensley <barton.wensley@windriver.com>
This commit is contained in:
Bart Wensley 2018-11-29 12:27:05 -06:00
parent ac6339b3c3
commit 0db51c47da
1 changed files with 11 additions and 14 deletions

View File

@ -1419,20 +1419,17 @@ class NFVIInfrastructureAPI(nfvi.api.v1.NFVIInfrastructureAPI):
raise raise
if self._host_supports_kubernetes(host_personality): if self._host_supports_kubernetes(host_personality):
if 'controller' in host_personality and \ if True:
'compute' in host_personality: # For now, we do not want to apply the NoExecute taint.
# This is an AIO host (either simplex or duplex). For now, # When the VIM detects that a service is failed on a host,
# we do not want to apply the NoExecute taint. When # it goes through a disable/enable cycle. This would cause
# the host reboots (e.g. on a lock/unlock), the VIM will # the NoExecute taint to be applied/removed which causes
# not initialize if it cannot register with rabbitmq # most pods to be stopped/started. If the pods don't come
# (which is running in a pod). But the VIM must first # back quickly enough the VIM will attempt another
# remove the NoExecute taint, before that pod will run. # disable/enable, which can go on forever. For now,
# This is only necessary on AIO simplex hosts, but we have # we will just avoid tainting hosts.
# no way to know whether the host is simplex or duplex # TODO(bwensley): Rework when support for pure k8s hosts is
# in this plugin. Long term, this decision will be moved to # added.
# the VIM, before invoking the plugin, once the plugins are
# refactored into separate enable/disable functions for
# nova, neutron, kubernetes, etc...
pass pass
else: else:
response['reason'] = 'failed to disable kubernetes services' response['reason'] = 'failed to disable kubernetes services'