大网数据广告活动
服务器运维问答

systemd-networkd not launching DHCPv6 client

· 52CE 我爱测

The systemd-networkd documentation makes this statement... By enabling DHCPv6 support explicitly, the DHCPv6 client will be started regardless of the presence of routers on the link This is the behavior I'm looking for - ignoring…

问题原文

原帖链接 · Coops · CC BY-SA 4.0

The systemd-networkd documentation makes this statement...

By enabling DHCPv6 support explicitly, the DHCPv6 client will
be started regardless of the presence of routers on the link

This is the behavior I'm looking for - ignoring any RAs which may or may not appear, and just launching a DHCPv6 client.

I see no evidence that networkd is launching a dhcpv6 client, either from the output of SYSTEMD_LOG_LEVEL=debug /lib/systemd/systemd-networkd or from tcpdump.

I can however confirm my DHCPv6 server is working if I manually evoke dhclient.

root@client:~# dhclient -6 -v eth0
[...]
XMT: Solicit on eth0, interval 1070ms.
RCV: Advertise message on eth0 from fe80::baae:edff:fe77:7798.
[...]
XMT: Request on eth0, interval 910ms.
RCV: Reply message on eth0 from fe80::baae:edff:fe77:7798.
[...]
RCV:  | | X-- IAADDR fd11:7::175
RCV:  | | | X-- Preferred lifetime 7200.
RCV:  | | | X-- Max lifetime 7500.
RCV:  X-- Server ID: 00:01:00:01:29:d9:12:a2:02:42:0a:fe:fe:fe
message status code Success: "success"
PRC: Bound to lease 00:01:00:01:29:d9:12:a2:02:42:0a:fe:fe:fe.

The systemd-network config (as produced by netplan).

[Match]
MACAddress=xx:xx:xx:xx:xx:xx
Name=eth0

[Network]
DHCP=ipv6   <-- explicitly enabling dhcpv6
LinkLocalAddressing=ipv6
Address=192.168.0.1/24
IPv6AcceptRA=no

[Route]
Destination=0.0.0.0/0
Gateway=192.168.0.10

Any ideas as to why networkd is not launching the DHCPv6 client?

已采纳解答

原帖链接 · Coops · CC BY-SA 4.0

Ok, it seems WithoutRA=solicit is the setting needed under [DHCPv6].

I might file an issue with the docs, as this seems contradictory to statement in the [Network] section.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2022-04-01)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。