instance uuid not cleared in an ironic node
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Hironori Shiina |
Bug Description
Description
===========
In nova with ironic environment, "instance UUID" still remains if nova boot
got an error. As a result, the ironic node cannot delete by API and deploy
baremetal instance.
Steps to reproduce
==================
1. create an ironic-node
2. create an ironic-port
3. nova boot for ironic instance with following illegal instance name.
$ nova boot --flavor my-baremetal-agent --image $MY_IMAGE_UUID \
Expected result
===============
Nova got an error and state has changed "ERROR". Then, tenant user deletes
nova's instance($nova delete <instance_uuid>). After that, "instance UUID"
of an ironic node should be cleared.
Actual result
=============
After $nova delete <instance_uuid>, "instance UUID" still remains into the
ironic node database.
$ ironic node-delete 0ea7c2e3-
Failed to delete node 0ea7c2e3-
Environment
===========
* Devstack all-in-one
* Nova's source code is for "May 18".
commit fe8a119e8d80de3
Merge: b56d861 6f2a46f
Author: Jenkins <email address hidden>
Date: Wed May 18 23:33:00 2016 +0000
Merge "Remove unused base_options param from _get_image_
2. Which hypervisor did you use?
ironic
3. Which networking type did you use?
(For example: nova-network, Neutron with OpenVSwitch, ...)
neutron + ML2 + openvswitch driver + linuxbridge driver
Logs
====
2016-06-28 21:03:04.670 ERROR nova.scheduler.
urukawa-dev-ironic (node 0ea7c2e3-
ild_and_
n=six.text_
valid PQDN or FQDN. Reason: TLD '141592' must not be all numeric.\n"]
2016-06-28 21:03:04.689 DEBUG oslo_messaging.
ly queue: reply_a163275e9
ver.py:74
2016-06-28 21:03:04.688 DEBUG oslo_messaging.
va' topic 'scheduler' from (pid=5507) _send /usr/local/
2016-06-28 21:03:04.741 DEBUG oslo_messaging.
t-packages/
2016-06-28 21:03:04.743 WARNING nova.scheduler.
are not enough hosts available.
Traceback (most recent call last):
File "/usr/local/
return func(*args, **kwargs)
File "/opt/stack/
dests = self.driver.
File "/opt/stack/
raise exception.
NoValidHost: No valid host was found. There are not enough hosts available.
Changed in nova: | |
assignee: | nobody → Hironori Shiina (shiina-hironori) |
It looks like the issue is solely that Ironic's cleanup should get called and do this here - https:/ /github. com/openstack/ nova/blob/ 4e62960722caaef d02f6fdc753176a 7c117f6a18/ nova/virt/ ironic/ driver. py#L838