[Bug 1734167] Re: DNS doesn't work in no-cloud as launched by ubuntu
Ryan Harper
1734167 at bugs.launchpad.net
Mon Nov 27 20:52:36 UTC 2017
I suspect because in bionic/artful we're missing resolvconf package, that the systemd-resolved service ends up starting later in boot. The systemd-resolved-update-resolveconf.{service,path} require /sbin/resolvconf to run; this service had a path-based trigger that would get hooked whenever DHCP clients would call resolvconf to kick off a DNS update once config was available.
I suspect that systemd-networkd itself isn't poking DNS service properly after acquiring information.
The dependency loop comes from systemd-resolved using default
dependencies which run after when cloud-init.service would run.
This then needs systemd-resolved to specify DefaultDependencies=No and
something like network-online.target to require systemd-resolved.
I modified cloud-init.service to include an After=systemd-
resolved.service but some other service may require dns, so I feel this
is a property of network-online.target.
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1734167
Title:
DNS doesn't work in no-cloud as launched by ubuntu
Status in cloud-init:
Confirmed
Status in cloud-init package in Ubuntu:
Confirmed
Status in systemd package in Ubuntu:
Confirmed
Status in cloud-init source package in Zesty:
Fix Released
Status in systemd source package in Zesty:
Fix Released
Status in cloud-init source package in Artful:
Confirmed
Status in systemd source package in Artful:
Confirmed
Status in cloud-init source package in Bionic:
Confirmed
Status in systemd source package in Bionic:
Confirmed
Bug description:
I use no-cloud to test the kernel in CI (I am maintainer of the bcache
subsystem), and have been running it successfully under 16.04 cloud
images from qemu, using a qemu command that includes:
-smbios "type=1,serial=ds=nocloud-
net;s=https://raw.githubusercontent.com/mlyle/mlyle/master/cloud-
metadata/linuxtst/"
As documented here:
http://cloudinit.readthedocs.io/en/latest/topics/datasources/nocloud.html
Under the new 17.10 cloud images, this doesn't work: the network comes
up, but name resolution doesn't work-- /etc/resolv.conf is a symlink
to a nonexistent file at this point of the boot and systemd-resolved
is not running. When I manually hack /etc/resolv.conf in the cloud
image to point to 4.2.2.1 it works fine.
I don't know if nameservice not working is by design, but it seems
like it should work. The documentation states:
"With ds=nocloud-net, the seedfrom value must start with http://,
https:// or ftp://"
And https is not going to work for a raw IP address.
To manage notifications about this bug go to:
https://bugs.launchpad.net/cloud-init/+bug/1734167/+subscriptions
More information about the foundations-bugs
mailing list