[Bug 1872589] [NEW] systemd-networkd is not honoring UseRoutes=false
Rafael David Tinoco
rafaeldtinoco at ubuntu.com
Tue Apr 14 03:36:07 UTC 2020
Public bug reported:
When netplan configures dhcp4-overrides and set "use-routes" to false,
systemd-networkd should be configured with UseRoutes=false. It is.
Unfortunately looks like systemd-networkd is not honoring it and
configuring the default gateways for the interfaces no matter what.
Ubuntu Focal: systemd: 245.4-2ubuntu1
----
$ sudo cat /etc/netplan/50-cloud-init.yaml
network:
ethernets:
enp5s0:
match:
macaddress: 00:16:3e:af:c4:d6
set-name: eth0
dhcp4: true
dhcp-identifier: mac
enp6s0:
match:
macaddress: 00:16:3e:50:11:9c
set-name: iscsi01
dhcp4: true
dhcp-identifier: mac
dhcp4-overrides:
use-routes: false
enp7s0:
match:
macaddress: 00:16:3e:b3:cc:50
set-name: iscsi02
dhcp4: true
dhcp-identifier: mac
dhcp4-overrides:
use-routes: false
version: 2
renderer: networkd
----
$ cat /var/run/systemd/network/10-netplan-enp6s0.network
[Match]
MACAddress=00:16:3e:50:11:9c
Name=iscsi01
[Network]
DHCP=ipv4
LinkLocalAddressing=ipv6
[DHCP]
ClientIdentifier=mac
RouteMetric=100
UseMTU=true
UseRoutes=false
--
$ ip route show | grep default
default via 10.250.93.1 dev iscsi02 proto dhcp src 10.250.93.101 metric 100
default via 10.250.94.1 dev iscsi01 proto dhcp src 10.250.94.167 metric 100
default via 10.250.97.1 dev eth0 proto dhcp src 10.250.97.123 metric 100
** Affects: systemd (Ubuntu)
Importance: Undecided
Status: Triaged
** Changed in: systemd (Ubuntu)
Status: New => Confirmed
** Changed in: systemd (Ubuntu)
Status: Confirmed => Triaged
** Description changed:
+ When netplan configures dhcp4-overrides and set "use-routes" to false,
+ systemd-networkd should be configured with UseRoutes=false. It is.
+ Unfortunately looks like systemd-networkd is not honoring it and
+ configuring the default gateways for the interfaces no matter what.
- When netplan configures dhcp4-overrides and set "use-routes" to false, systemd-networkd should be configured with UseRoutes=false. It is. Unfortunately looks like systemd-networkd is not honoring it and configuring the default gateways for the interfaces no matter what.
+ Ubuntu Focal: systemd: 245.4-2ubuntu1
----
$ sudo cat /etc/netplan/50-cloud-init.yaml
network:
- ethernets:
- enp5s0:
- match:
- macaddress: 00:16:3e:af:c4:d6
- set-name: eth0
- dhcp4: true
- dhcp-identifier: mac
- enp6s0:
- match:
- macaddress: 00:16:3e:50:11:9c
- set-name: iscsi01
- dhcp4: true
- dhcp-identifier: mac
- dhcp4-overrides:
- use-routes: false
- enp7s0:
- match:
- macaddress: 00:16:3e:b3:cc:50
- set-name: iscsi02
- dhcp4: true
- dhcp-identifier: mac
- dhcp4-overrides:
- use-routes: false
- version: 2
- renderer: networkd
+ ethernets:
+ enp5s0:
+ match:
+ macaddress: 00:16:3e:af:c4:d6
+ set-name: eth0
+ dhcp4: true
+ dhcp-identifier: mac
+ enp6s0:
+ match:
+ macaddress: 00:16:3e:50:11:9c
+ set-name: iscsi01
+ dhcp4: true
+ dhcp-identifier: mac
+ dhcp4-overrides:
+ use-routes: false
+ enp7s0:
+ match:
+ macaddress: 00:16:3e:b3:cc:50
+ set-name: iscsi02
+ dhcp4: true
+ dhcp-identifier: mac
+ dhcp4-overrides:
+ use-routes: false
+ version: 2
+ renderer: networkd
----
$ cat /var/run/systemd/network/10-netplan-enp6s0.network
[Match]
MACAddress=00:16:3e:50:11:9c
Name=iscsi01
[Network]
DHCP=ipv4
LinkLocalAddressing=ipv6
[DHCP]
ClientIdentifier=mac
RouteMetric=100
UseMTU=true
UseRoutes=false
--
$ ip route show | grep default
default via 10.250.93.1 dev iscsi02 proto dhcp src 10.250.93.101 metric 100
default via 10.250.94.1 dev iscsi01 proto dhcp src 10.250.94.167 metric 100
default via 10.250.97.1 dev eth0 proto dhcp src 10.250.97.123 metric 100
--
You received this bug notification because you are a member of Ubuntu
Server, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1872589
Title:
systemd-networkd is not honoring UseRoutes=false
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1872589/+subscriptions
More information about the Ubuntu-server-bugs
mailing list