If you don't recreate Neutron ports (just destroying VM, creating it as new and attaching old ports), then you can distinguish between interfaces by MAC addresses and store this in udev rules. You can do this on first boot (e.g. in cloud-init's "startcmd" command), using information from /sys/class/net directory.

On 7/31/17 9:14 PM, Morgenstern, Chad wrote:

Hi,

I am trying to programmatically rebuild a nova instance that has a persistent volume for its root device.

I am specifically trying to rebuild an instance that has multiple network interfaces and a floating ip.

I have observed that the order in which the network interface are attached matters, floating ip attach to eth0 based.

How do I figure out which of the interfaces currently attached is associated with eth0?



_______________________________________________
OpenStack-operators mailing list
OpenStack-operators@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-operators

--
Volodymyr Litovka
  "Vision without Execution is Hallucination." -- Thomas Edison

_______________________________________________
OpenStack-operators mailing list
OpenStack-operators@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-operators

Reply via email to