Comment 0 for bug 1796917

Revision history for this message
Dan Watkins (oddbloke) wrote :

When cloud-init runs in the latest cosmic minimal image, we see the following traceback:

cloud-init[108]: Traceback (most recent call last):
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/cmd/main.py", line 658, in status_wrapper
cloud-init[108]: ret = functor(name, args)
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/cmd/main.py", line 362, in main_init
cloud-init[108]: init.apply_network_config(bring_up=bool(mode != sources.DSMODE_LOCAL))
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/stages.py", line 648, in apply_network_config
cloud-init[108]: netcfg, src = self._find_networking_config()
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/stages.py", line 635, in _find_networking_config
cloud-init[108]: if self.datasource and hasattr(self.datasource, 'network_config'):
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/sources/DataSourceOpenStack.py", line 115, in network_config
cloud-init[108]: self.network_json, known_macs=None)
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/sources/helpers/openstack.py", line 655, in convert_net_json
cloud-init[108]: known_macs = net.get_interfaces_by_mac()
cloud-init[108]: File "/usr/lib/python3/dist-packages/cloudinit/net/__init__.py", line 595, in get_interfaces_by_mac
cloud-init[108]: (name, ret[mac], mac))
cloud-init[108]: RuntimeError: duplicate mac found! both 'sit0' and 'tunl0' have mac '00:00:00:00'

It appears that the devices presented by the latest linux-kvm is now different; this is the table output by cloud-init in the previous minimal image:

cloud-init[237]: ci-info: +++++++++++++++++++++++++++++++++++++++Net device info++++++++++++++++++++++++++++++++++++++++
cloud-init[237]: ci-info: +--------+-------+------------------------------+---------------+--------+-------------------+
cloud-init[237]: ci-info: | Device | Up | Address | Mask | Scope | Hw-Address |
cloud-init[237]: ci-info: +--------+-------+------------------------------+---------------+--------+-------------------+
cloud-init[237]: ci-info: | ens2 | True | 10.220.168.37 | 255.255.255.0 | global | fa:16:3e:ef:89:9a |
cloud-init[237]: ci-info: | ens2 | True | fe80::f816:3eff:feef:899a/64 | . | link | fa:16:3e:ef:89:9a |
cloud-init[237]: ci-info: | lo | True | 127.0.0.1 | 255.0.0.0 | host | . |
cloud-init[237]: ci-info: | lo | True | ::1/128 | . | host | . |
cloud-init[237]: ci-info: | sit0 | False | . | . | . | . |
cloud-init[237]: ci-info: +--------+-------+------------------------------+---------------+--------+-------------------+

Whereas the new image shows:

cloud-init[234]: ci-info: +++++++++++++++++++++++++++Net device info++++++++++++++++++++++++++++
cloud-init[234]: ci-info: +--------+-------+-----------+-----------+-------+-------------------+
cloud-init[234]: ci-info: | Device | Up | Address | Mask | Scope | Hw-Address |
cloud-init[234]: ci-info: +--------+-------+-----------+-----------+-------+-------------------+
cloud-init[234]: ci-info: | ens2 | False | . | . | . | fa:16:3e:15:a7:3b |
cloud-init[234]: ci-info: | lo | True | 127.0.0.1 | 255.0.0.0 | host | . |
cloud-init[234]: ci-info: | lo | True | ::1/128 | . | host | . |
cloud-init[234]: ci-info: | sit0 | False | . | . | . | . |
cloud-init[234]: ci-info: | tunl0 | False | . | . | . | . |
cloud-init[234]: ci-info: +--------+-------+-----------+-----------+-------+-------------------+