summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2022-01-18 13:23:31 +0000
committerGerrit Code Review <review@openstack.org>2022-01-18 13:23:31 +0000
commit913a14e731ebc6bb45d2a9bb37b43215c7343fe3 (patch)
tree4c4bc576c273fbbcae1572057a05b03904813e83
parent4b317360dfb6ec942307d23cc57df327440ae9e4 (diff)
parent30eb576d1cbfe0e745b9b4b69426201daacc6d4b (diff)
downloadironic-913a14e731ebc6bb45d2a9bb37b43215c7343fe3.tar.gz
Merge "Trivial: log current state when continuing cleaning" into bugfix/18.1
-rw-r--r--ironic/conductor/cleaning.py4
-rw-r--r--ironic/drivers/modules/agent_base.py10
2 files changed, 9 insertions, 5 deletions
diff --git a/ironic/conductor/cleaning.py b/ironic/conductor/cleaning.py
index 1ea35bfcf..752f07e6a 100644
--- a/ironic/conductor/cleaning.py
+++ b/ironic/conductor/cleaning.py
@@ -154,9 +154,9 @@ def do_next_clean_step(task, step_index, disable_ramdisk=None):
disable_ramdisk = node.driver_internal_info.get(
'cleaning_disable_ramdisk', False)
- LOG.info('Executing %(state)s on node %(node)s, remaining steps: '
+ LOG.info('Executing %(kind)s cleaning on node %(node)s, remaining steps: '
'%(steps)s', {'node': node.uuid, 'steps': steps,
- 'state': node.provision_state})
+ 'kind': 'manual' if manual_clean else 'automated'})
# Execute each step until we hit an async step or run out of steps
for ind, step in enumerate(steps):
diff --git a/ironic/drivers/modules/agent_base.py b/ironic/drivers/modules/agent_base.py
index 95570c61c..a0defe3ad 100644
--- a/ironic/drivers/modules/agent_base.py
+++ b/ironic/drivers/modules/agent_base.py
@@ -500,8 +500,11 @@ class HeartbeatMixin(object):
try:
node.touch_provisioning()
if not node.clean_step:
- LOG.debug('Node %s just booted to start cleaning.',
- node.uuid)
+ kind = ('manual'
+ if node.target_provision_state == states.MANAGEABLE
+ else 'automated')
+ LOG.debug('Node %s just booted to start %s cleaning',
+ node.uuid, kind)
msg = _('Node failed to start the first cleaning step')
# First, cache the clean steps
self.refresh_clean_steps(task)
@@ -570,7 +573,8 @@ class HeartbeatMixin(object):
return
node = task.node
- LOG.debug('Heartbeat from node %s', node.uuid)
+ LOG.debug('Heartbeat from node %s in state %s (target state %s)',
+ node.uuid, node.provision_state, node.target_provision_state)
driver_internal_info = node.driver_internal_info
driver_internal_info['agent_url'] = callback_url
driver_internal_info['agent_version'] = agent_version