Something related to NetworkManager is preventing systemd-networkd from starting.
networkd-dispatcher[1163]: WARNING: systemd-networkd is not running, output will be incomplete.
Normally after network-pre.target, systemd-networkd-wait-online.service runs
and blocks until systemd-networkd has brough up configured interfaces.
systemd-networkd did not start so when cloud-init.service runs network is
*not* up like it expects.
Notice later, NetworkManager takes over the ethernet device:
kernel: r8169 0000:02:00.0 enp2s0: Link is Up - 1Gbps/Full - flow control rx/tx
kernel: IPv6: ADDRCONF(NETDEV_CHANGE): enp2s0: link becomes ready
NetworkManager[1035]: <info> [1586324867.0369] device (enp2s0): carrier: link connected
NetworkManager[1035]: <info> [1586324867.0380] device (enp2s0): state change: unavailable -> disconnected (reason 'carrier-changed', sys-iface-state: 'managed')
NetworkManager[1035]: <info> [1586324867.0403] policy: auto-activating connection 'netplan-enp2s0' (7ea6f90b-3495-3533-948a-ef0035687c34)
NetworkManager[1035]: <info> [1586324867.0425] device (enp2s0): Activation: starting connection 'netplan-enp2s0' (7ea6f90b-3495-3533-948a-ef0035687c34)
NetworkManager[1035]: <info> [1586324867.0430] device (enp2s0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed')
NetworkManager[1035]: <info> [1586324867.0445] manager: NetworkManager state is now CONNECTING
NetworkManager[1035]: <info> [1586324867.0454] device (enp2s0): state change: prepare -> config (reason 'none', sys-iface-state: 'managed')
NetworkManager[1035]: <info> [1586324867.0470] device (enp2s0): state change: config -> ip-config (reason 'none', sys-iface-state: 'managed')
avahi-daemon[1011]: Joining mDNS multicast group on interface enp2s0.IPv4 with address 192.168.101.86.
The network config maas sends is for Ubuntu Server, which defaults ethernet
devices to be controlled by systemd-networkd; I suspect Desktop has a
different policy in place which puts all network devices in NetworkManager
control, so this config that MAAS sends (also, this MAAS looks old, it's
sending network config v1 (not v2, netplan)).
Something related to NetworkManager is preventing systemd-networkd from starting.
networkd- dispatcher[ 1163]: WARNING: systemd-networkd is not running, output will be incomplete.
Normally after network-pre.target, systemd- networkd- wait-online. service runs
and blocks until systemd-networkd has brough up configured interfaces.
systemd-networkd did not start so when cloud-init.service runs network is
*not* up like it expects.
systemd[1]: Finished Initial cloud-init job (pre-networking). g71af48df- 0ubuntu2 running 'init' at Wed, 08 Apr 2020 05:45:26 +0000. Up 31.04 seconds. +++++++ +++++++ +++++++ +Net device info+++ +++++++ +++++++ +++++++ +++++ -----+- ------+ ------- ----+-- ------- --+---- ---+--- ------- ------- --+ -----+- ------+ ------- ----+-- ------- --+---- ---+--- ------- ------- --+
systemd[1]: Reached target Network (Pre).
systemd[1]: Starting Initial cloud-init job (metadata service crawler)...
cloud-init[931]: Cloud-init v. 20.1-10-
cloud-init[931]: ci-info: +++++++
cloud-init[931]: ci-info: +------
cloud-init[931]: ci-info: | Device | Up | Address | Mask | Scope | Hw-Address |
cloud-init[931]: ci-info: +------
cloud-init[931]: ci-info: | enp2s0 | False | . | . | . | 6c:2b:59:59:9d:ca |
Notice later, NetworkManager takes over the ethernet device:
kernel: r8169 0000:02:00.0 enp2s0: Link is Up - 1Gbps/Full - flow control rx/tx NETDEV_ CHANGE) : enp2s0: link becomes ready 1035]: <info> [1586324867.0369] device (enp2s0): carrier: link connected 1035]: <info> [1586324867.0380] device (enp2s0): state change: unavailable -> disconnected (reason 'carrier-changed', sys-iface-state: 'managed') 1035]: <info> [1586324867.0403] policy: auto-activating connection 'netplan-enp2s0' (7ea6f90b- 3495-3533- 948a-ef0035687c 34) 1035]: <info> [1586324867.0425] device (enp2s0): Activation: starting connection 'netplan-enp2s0' (7ea6f90b- 3495-3533- 948a-ef0035687c 34) 1035]: <info> [1586324867.0430] device (enp2s0): state change: disconnected -> prepare (reason 'none', sys-iface-state: 'managed') 1035]: <info> [1586324867.0445] manager: NetworkManager state is now CONNECTING 1035]: <info> [1586324867.0454] device (enp2s0): state change: prepare -> config (reason 'none', sys-iface-state: 'managed') 1035]: <info> [1586324867.0470] device (enp2s0): state change: config -> ip-config (reason 'none', sys-iface-state: 'managed')
kernel: IPv6: ADDRCONF(
NetworkManager[
NetworkManager[
NetworkManager[
NetworkManager[
NetworkManager[
NetworkManager[
NetworkManager[
NetworkManager[
avahi-daemon[1011]: Joining mDNS multicast group on interface enp2s0.IPv4 with address 192.168.101.86.
The network config maas sends is for Ubuntu Server, which defaults ethernet
devices to be controlled by systemd-networkd; I suspect Desktop has a
different policy in place which puts all network devices in NetworkManager
control, so this config that MAAS sends (also, this MAAS looks old, it's
sending network config v1 (not v2, netplan)).
network:
mac_address: 6c:2b:59:59:9d:ca
dns_ nameservers:
dns_ search:
gateway: 192.168.101.1
gateway: 192.168.101.1
metric: 200
config:
- id: enp2s0
mtu: 1500
name: enp2s0
subnets:
- address: 192.168.101.86/24
- 192.168.101.1
- maas
routes:
- destination: 10.101.46.0/24
type: static
type: physical
- address:
- 192.168.101.1
search:
- maas
type: nameserver
version: 1
On Focal desktops, this file is now present:
% cat /etc/netplan/ 01-network- manager- all.yaml
# Let NetworkManager manage all devices on this system
network:
version: 2
renderer: NetworkManager
You will need to use a script/preseed to modify this value to
be networkd like this:
network:
version: 2
renderer: networkd