[Bug 1779721] Re: systemd-networkd does not configure DHCPv4
Andrew Jones
1779721 at bugs.launchpad.net
Wed Aug 15 10:46:40 UTC 2018
This bug in systemd-networkd is affecting our environment also.
We have an RFC-compliant DHCP server that does not reply with Option 54
"Server Identifier". We have made the point to other vendors that this
is indeed compliant with the RFC because there is no routable address to
the DHCP server so it is not possible to send this option and also stay
in line with the RFC.
For context, the reason there is no routable address as this server
works in a cloud environment where it impersonates a server in multiple
VLANs that belong to customers. It cannot use addresses in those
subnets.
`To accommodate potentially incomplete network connectivity, a server MUST choose an address as a 'server identifier' that, to the best of the server's knowledge, is reachable from the client.`
This is the reason why its not possible to send the option in the DHCPOFFER as there is no such address.
There is good support for this implementation from other software such as the ISC dhclient and from Windows.
--
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/1779721
Title:
systemd-networkd does not configure DHCPv4
Status in netplan.io package in Ubuntu:
Invalid
Status in systemd package in Ubuntu:
Confirmed
Bug description:
I have an up-to-date Ubuntu 18.04 (bionic) server installation (with
systemd 237-3ubuntu10) which has following netplan configuration:
```
root at ubuntu:~# cat /etc/netplan/01-netcfg.yaml
# This file describes the network interfaces available on your system
# For more information, see netplan(5).
network:
version: 2
renderer: networkd
ethernets:
all:
match: {}
dhcp4: yes
root at ubuntu:~# cat /run/systemd/network/10-netplan-all.network
[Match]
[Network]
DHCP=ipv4
[DHCP]
UseMTU=true
RouteMetric=100
```
Despite having DHCPv4 configured, no IPv4 address is configured on the
ethernet device:
```
root at ubuntu:~# ip a show ens6
2: ens6: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 64000 qdisc fq_codel state UP group default qlen 1000
link/ether 02:01:71:8f:cc:72 brd ff:ff:ff:ff:ff:ff
inet6 fe80::1:71ff:fe8f:cc72/64 scope link
valid_lft forever preferred_lft forever
```
The kernel dmesg has no related messages and the journal log also
looks normal:
```
root at ubuntu:~# journalctl -u systemd-networkd
Jul 02 16:36:51 ubuntu systemd[1]: Starting Network Service...
Jul 02 16:36:51 ubuntu systemd-networkd[1790]: ens6: Gained IPv6LL
Jul 02 16:36:51 ubuntu systemd-networkd[1790]: Enumeration completed
Jul 02 16:36:51 ubuntu systemd[1]: Started Network Service.
Jul 02 16:36:51 ubuntu systemd-networkd[1790]: lo: Link is not managed by us
Jul 02 16:36:51 ubuntu systemd-networkd[1790]: lo: Configured
```
Calling dhclient sets up the device correctly:
```
root at ubuntu:~# dhclient ens6
root at ubuntu:~# cat /var/lib/dhcp/dhclient.leases
lease {
interface "ens6";
fixed-address 87.106.172.36;
option subnet-mask 255.255.255.255;
option dhcp-lease-time 600;
option routers 87.106.172.1;
option dhcp-message-type 5;
option domain-name-servers 46.16.74.70,46.16.72.37;
option dhcp-server-identifier 87.106.172.1;
option interface-mtu 64000;
option host-name "ubuntu-18_04-fkb-2018-07-02";
renew 1 2018/07/02 16:46:51;
rebind 1 2018/07/02 16:51:31;
expire 1 2018/07/02 16:52:46;
}
root at ubuntu:~# ip a show ens6
2: ens6: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 64000 qdisc fq_codel state UP group default qlen 1000
link/ether 02:01:71:8f:cc:72 brd ff:ff:ff:ff:ff:ff
inet 87.106.172.36/32 brd 87.106.172.36 scope global ens6
valid_lft forever preferred_lft forever
inet6 fe80::1:71ff:fe8f:cc72/64 scope link
valid_lft forever preferred_lft forever
```
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/netplan.io/+bug/1779721/+subscriptions
More information about the foundations-bugs
mailing list