You are not logged in.

#1 2023-10-04 02:42:49

Uncommon2729
Member
Registered: 2023-10-04
Posts: 1

systemd-networkd dhcp client send hostname with request

I have a pretty basic Arch install and figured I'd use systemd-networkd to handle networking.  I have most things working except for one little item.  When the dhcp client requests an address from the dhcp server, it does not send the hostname of the computer like my other Linux boxes.  I've used hostnamectl to set the hostname.  My network file in /etc/systemd/network has the following:

[Match]
Name=ens18

[Network]
DHCP=yes

[DHCPv4]
SendHostname=true

I am on version 254.1-1 of systemd.  Is there any other tasks that I need to do to get this working?

Offline

#2 2023-10-04 06:30:25

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 76,082

Re: systemd-networkd dhcp client send hostname with request

SendHostname defaults to "true" anyway.
Please post the outputs of

hostnamectl; ip a; 
find /etc/systemd -type l -exec test -f {} \; -print | awk -F'/' '{ printf ("%-40s | %s\n", $(NF-0), $(NF-1)) }' | sort -f

Did you try whether eg. dhcpcd behaves as expected?

Offline

Board footer

Powered by FluxBB