cloud-init init fails on 18.04 in the networking part
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init (Ubuntu) |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
I use the following cloud-init configuration works perfectly for Ubuntu 14.04, Ubuntu 16.04, Debian 8, Debian 9 and Centos 7 but not with the new Ubuntu 18.04
--- 8< 8< 8< ---
#cloud-config
datasource:
Ec2:
strict_id: false
hostname: my_cloudserver_name
phone_home:
url: http://
post: [ instance_id ]
tries: 10
users:
- default
ssh_authorized_
- "ssh-rsa AAA ....=="
--- 8< 8< 8< ---
The installation process hangs here and will fail:
2018-02-01 13:37:47,126 - DataSourceEc2.
2018-02-01 13:37:47,126 - util.py[WARNING]: failed stage init
failed run of stage init
-------
Traceback (most recent call last):
File "/usr/lib/
ret = functor(name, args)
File "/usr/lib/
init.
File "/usr/lib/
netcfg, src = self._find_
File "/usr/lib/
if self.datasource and hasattr(
File "/usr/lib/
macs_to_nics = {net.get_
File "/usr/lib/
if os.path.
File "/usr/lib/
return get_sys_
TypeError: must be str, not NoneType
-------
after adding:
--- 8< 8< 8< ---
packages:
- ifupdown
--- 8< 8< 8< ---
the cloud-init works as wished.
---
...
ci-info: +------
2018-02-01 14:19:41,576 - DataSourceEc2.
2018-02-01 14:19:41,777 - cc_resizefs.
Generating public/private rsa key pair.
...
---
It seems there is a dependency in cloud-init to the pre-netplan networking system in 18.04.
root@cloud- nine-141: /var/lib/ cloud# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu Bionic Beaver (development branch)
Release: 18.04
Codename: bionic