yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #82849
[Bug 1881806] Re: cloud-init fails to initialize with virtual router
This issue has already been fixed in upstream cloud-init, see:
https://github.com/canonical/cloud-
init/commit/5352dd99eb2937b4eaaaf596b40ad7ca69d87f64
And
https://bugs.launchpad.net/cloud-init/+bug/1639263
For downstream, you'll need RedHat/Centos to cherry pick this commit.
If possible, you can test with our daily rpm build for Centos8 using
this COPR repo:
https://copr.fedorainfracloud.org/coprs/g/cloud-init/cloud-init-dev/
** Changed in: cloud-init
Status: New => Invalid
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to cloud-init.
https://bugs.launchpad.net/bugs/1881806
Title:
cloud-init fails to initialize with virtual router
Status in cloud-init:
Invalid
Status in CentOS:
Unknown
Bug description:
Cloud-init fails to initialize with RHEL8.1 and CentOS8.1 (RPM cloud-
init-18.5-7.el8_1.1.noarch) when routing to the VMs are provider by
virtual router (vrouter). In this scenario, we are spawning a VM on
OpenStack using Contrail as the network provider. With cloud-init-18.5
version, we see the following exception during the VM boot phase
causing init and final stages of cloud-init to fail.
Impact: cloud-init fails to inject ssh-keys, grow root partition and
other critical functions.
Version cloud-init-18.2-6.el8.noarch of cloud-init did not have this
issue.
Reproducibility: always
2020-06-02 19:17:15,641 - util.py[WARNING]: failed stage init
failed run of stage init
------------------------------------------------------------
Traceback (most recent call last):
File "/usr/lib/python3.6/site-packages/cloudinit/cmd/main.py", line 652, in status_wrapper
ret = functor(name, args)
File "/usr/lib/python3.6/site-packages/cloudinit/cmd/main.py", line 362, in main_init
init.apply_network_config(bring_up=bool(mode != sources.DSMODE_LOCAL))
File "/usr/lib/python3.6/site-packages/cloudinit/stages.py", line 649, in apply_network_config
netcfg, src = self._find_networking_config()
File "/usr/lib/python3.6/site-packages/cloudinit/stages.py", line 636, in _find_networking_config
if self.datasource and hasattr(self.datasource, 'network_config'):
File "/usr/lib/python3.6/site-packages/cloudinit/sources/DataSourceOpenStack.py", line 115, in network_config
self.network_json, known_macs=None)
File "/usr/lib/python3.6/site-packages/cloudinit/sources/helpers/openstack.py", line 645, in convert_net_json
'Unknown network_data link type: %s' % link['type'])
ValueError: Unknown network_data link type: vrouter
The error seems to be coming from
cloudinit/sources/helpers/openstack.py file which only expects 'link'
type to be only of one of the following:
valid_keys = {
'physical': [
'name',
'type',
'mac_address',
'subnets',
'params',
'mtu',
],
However, with Contrail, the network_config object that gets passed to
the method convert_net_json looks something like the following object:
{
"services": [],
"networks": [
{
"network_id": "f42c8806-c128-4ef8-af9e-d4a3856dde23",
"type": "ipv4",
"netmask": "255.255.255.192",
"link": "tap722bcc7f-5a",
"routes": [
{
"netmask": "0.0.0.0",
"network": "0.0.0.0",
"gateway": "10.140.145.126"
}
],
"ip_address": "10.140.145.110",
"id": "network0"
}
],
"links": [
{
"type": "vrouter",
"vif_id": "722bcc7f-5ae5-4564-ad43-ff9a5357dd36",
"ethernet_mac_address": "02:72:2b:cc:7f:5a",
"id": "tap722bcc7f-5a",
"mtu": null
}
]
}
To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1881806/+subscriptions
References