[systemd-devel] systemd-networkd override hostname not being sent to DHCP

Andy Pieters systemd at andypieters.me.uk
Thu Apr 2 12:47:13 UTC 2020


Hi

I have a network file like this:

---
[Match]
Name=enp2s0

[Network]
DHCP=ipv4
Domains=faster rstore
Hostname=myhostname
SendHostname=True
----

After saving the file, doing a systemctl daemon-reload and a
systemdctl restart systemd-networkd it would seem that this is still
not being applied.

When I do a capture for the traffic, Wireshark tells me for instance
that the DHCP Discover packet sent to 255.255.255.255 includes the
following:

DHCP->Option: (81) Client FQDN: myothername.mycompany.tld

Which it repeats a few moments later in the DHCP Request packet


Host is Arch Linux 64 bit running 5.5.13
systemd 245 (245.3-2-arch)
+PAM +AUDIT -SELINUX -IMA -APPARMOR +SMACK -SYSVINIT +UTMP
+LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS
+KMOD +IDN2 -IDN +PCRE2 default-hierarchy=hybrid

Can anyone see what I am doing wrong here?

Thank you


Andy


More information about the systemd-devel mailing list