Currently, the driver_info['pxe']['instance_name'] property is used to determine the TFTP directory name for the instance's image storage. See ironic/drivers/modules/pxe.py:
188 def _get_image_dir_path(d_info):
189 """Generate the dir for an instances disk."""
190 return os.path.join(CONF.pxe.images_path, d_info['instance_name'])
There is presently no guarantee that the instance_name will be unique. In fact, it can be set and manipulated via Ironic's API at will by the cloud's admin, which could lead to unexpected behavior.
The history of this code is that, when the pxe driver was part of Nova, the instance_name was the instance UUID generated internally by Nova. This is now an external dependency that we can't rely on (not because we can't rely on Nova, but because this resource is writable via Ironic's API and Nova may not be the only client).
We should probably use the node's UUID instead of the instance's UUID, and this will need to be propagated out to dnsmasq's config file // neutron.
Fix proposed to branch: master /review. openstack. org/65657
Review: https:/