bionic: DNS search domains lost from cloud-init to netplan
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
cloud-init |
Expired
|
Medium
|
Unassigned |
Bug Description
On a deployed node with a MAAS datasource, /etc/cloud/
network:
config:
- id: enp1s0
mac_address: 52:54:00:9a:b4:64
mtu: 1500
name: enp1s0
subnets:
- address: 10.48.7.48/21
dns_
- 10.48.0.5
gateway: 10.48.0.1
type: static
type: physical
- address:
- 10.48.0.5
search:
- bos01.canonista
type: nameserver
version: 1
But the generated /etc/netplan/
# This file is generated from information provided by
# the datasource. Changes to it will not persist across an instance.
# To disable cloud-init's network configuration capabilities, write a file
# /etc/cloud/
# network: {config: disabled}
network:
version: 2
ethernets:
enp1s0:
- 10.48.7.48/21
match:
mtu: 1500
- 10.48.0.5
Related bugs:
* bug 1750884: /etc/resolv.conf not configured correctly in Bionic, leads to no DNS resolution
This is related to bug 1750884. systemd- networkd there is no such thing as "global" dns. The decision was made that although users configured dns globally for the vast majority of the last 30 years, we were not going to support that behavior any more in netplan or systemd-networkd.
In netplan/
Under that bug, though, cloud-init worked around by copying the 'nameserver' settings from the global section to each interface.
Curiously, though, we did not copy the search entries.
I am not sure why.