Comment 1 for bug 1792454

Revision history for this message
Ryan Harper (raharper) wrote :

Via IRC, the discussion mentions that the incoming eni file has ip/cidr vs ip/netmask.

OpenNebula Datasource now has a network_config property which returns netplan (v2) config.

Here's what's happening

cloudinit.stages.Init.apply_network_config
  cloudinit.distro.apply_network_config()
     cloudinit.distro.gentoo.apply_network_config() # this fails, not implemented
  cloudinit.distro._apply_network_from_network_config
     cloudinit.net.network_state.parse_net_config_data()
     cloudinit.net.eni.network_state_to_eni()
     cloudinit.distro.apply_network()
         cloudinit.distro.gentoo._write_network()

Thus this converts OpenNebula netplan into internal state, and then into eni, passing that to distros to call net_util.translate_settings.

The issue is that if the eni passed in uses address 192.168.23.1/24, then the parser does not provide a 'netmask' key in the returned dictionary which all of the distros using net_util expect.