Date: Tue, 30 Jul 2024 15:44:21 +0100 From: Roy Marples <roy@marples.name> To: "Karl Denninger" <karl@denninger.net> Cc: "freebsd-net" <freebsd-net@freebsd.org> Subject: Re: DHCPv6 IA_PD - how-to Message-ID: <1910419702c.f8dcf010456961.6536659919669261420@marples.name> In-Reply-To: <fb6a9b28-7d52-42d8-a9e3-cd693b746bd2@denninger.net> References: <050440F8-B3D8-4B2C-85BD-D5C09C303037@distal.com> <20240727.122108.862717899466090274.moto@kawasaki3.org> <190fdf3e353.11351bb5e292296.3216692081725884177@marples.name> <20240730.091027.1008656135460861216.moto@kawasaki3.org> <fb6a9b28-7d52-42d8-a9e3-cd693b746bd2@denninger.net>
next in thread | previous in thread | raw e-mail | index | archive | help
---- On Tue, 30 Jul 2024 15:06:17 +0100 Karl Denninger wrote ---=20 > Ok so I have a "new problem" attempting to use dhcp6c for BOTH = IPv4 and IPv6. > This is the salient part of the configuration file (the rest is = basically defaults): > # Generate SLAAC address using the Hardware Address of the inte= rface > #slaac hwaddr > # OR generate Stable Private IPv6 Addresses based from the DUID > #slaac private > =20 > allowinterfaces igb0 > =20 > #ipv6only > #ipv4only > =20 > # > # Do not run these hooks; DO run the DDNS one in exit-hooks > # > nohook resolv.conf hostname ntp.conf > =20 > interface igb0 > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ia_na 1 > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ia_pd 1/::/56 igb1/0/64= igb1.4/1/64 > =20 > If I do "ipv6only" and run dhcpcd -T then I do get a prefix: > root@IpGw:/usr/local/etc # dhcpcd -T > dhcpcd-10.0.8 starting > DUID 00:01:00:01:2e:3a:76:f1:00:0d:b9:46:71:88 > igb0: IAID b9:46:71:88 > igb0: IA type 3 IAID 00:00:00:01 > igb0: IA type 25 IAID 00:00:00:01 > igb0: soliciting a DHCPv6 lease > igb1: activating for delegation > igb1: IAID b9:46:71:89 > igb1.4: activating for delegation > igb1.4: IAID ff:00:00:04 > igb0: soliciting an IPv6 router > igb0: ADV 2600:6c5d:7009:600:c5e0:25ed:b364:36c2/128 from fe8= 0::201:5cff:fe70:7c46 > igb0: REPLY6 received from fe80::201:5cff:fe70:7c46 > interface=3Digb0 > pid=3D3395 > protocol=3Ddhcp6 > reason=3DTEST > skip_hooks=3D'resolv.conf hostname ntp.conf' > ifcarrier=3Dup > ifflags=3D34883 > ifmetric=3D1001 > ifmtu=3D1500 > ifwireless=3D0 > new_dhcp6_client_id=3D000100012e3a76f1000db9467188 > new_dhcp6_domain_search=3Dsearch.charter.net > new_dhcp6_ia_na1_ia_addr1=3D2600:6c5d:7009:600:c5e0:25ed:b364:36c2 > new_dhcp6_ia_na1_ia_addr1_pltime=3D3337 > new_dhcp6_ia_na1_ia_addr1_vltime=3D3337 > new_dhcp6_ia_na1_iaid=3D00000001 > new_dhcp6_ia_na1_t1=3D1537 > new_dhcp6_ia_na1_t2=3D2617 > new_dhcp6_ia_pd1_iaid=3D00000001 > new_dhcp6_ia_pd1_prefix1=3D2600:6c5d:5d00:9d00:: > new_dhcp6_ia_pd1_prefix1_length=3D56 > new_dhcp6_ia_pd1_prefix1_pltime=3D3337 > new_dhcp6_ia_pd1_prefix1_vltime=3D3337 > new_dhcp6_ia_pd1_t1=3D1537 > new_dhcp6_ia_pd1_t2=3D2617 > new_dhcp6_name_servers=3D'2607:f428:ffff:ffff::1 2607:f428:ff= ff:ffff::2' > new_dhcp6_server_id=3D000100012261b73d00144f9bcc84 > dhcpcd exited > =20 > This looks ok.=C2=A0 That prefix is good and I presume if I let it s= et the other interfaces it will be ok. > =20 > But if I do not say "ipv6only", leaving it that commented out so = I can get both, I get on dhcpcd -T: > root@IpGw:/usr/local/etc # dhcpcd -T > dhcpcd-10.0.8 starting > DUID 00:01:00:01:2e:3a:76:f1:00:0d:b9:46:71:88 > igb0: IAID b9:46:71:88 > igb0: IA type 3 IAID 00:00:00:01 > igb0: IA type 25 IAID 00:00:00:01 > igb0: soliciting a DHCPv6 lease > igb1: activating for delegation > igb1: IAID b9:46:71:89 > igb1.4: activating for delegation > igb1.4: IAID ff:00:00:04 > igb0: rebinding lease of 71.15.253.203 > igb0: leased 71.15.253.203 for 2813 seconds > interface=3Digb0 > pid=3D3358 > protocol=3Ddhcp > reason=3DTEST > skip_hooks=3D'resolv.conf hostname ntp.conf' > ifcarrier=3Dup > ifflags=3D34883 > ifmetric=3D1001 > ifmtu=3D1500 > ifwireless=3D0 > old_broadcast_address=3D255.255.255.255 > old_dhcp_lease_time=3D3600 > old_dhcp_message_type=3D5 > old_dhcp_rebinding_time=3D3150 > old_dhcp_renewal_time=3D1800 > old_dhcp_server_identifier=3D96.33.192.1 > old_domain_name_servers=3D'71.10.216.1 71.10.216.2' > old_interface_mtu=3D1500 > old_ip_address=3D71.15.253.203 > old_network_number=3D71.15.252.0 > old_routers=3D71.15.252.1 > old_subnet_cidr=3D22 > old_subnet_mask=3D255.255.252.0 > new_broadcast_address=3D255.255.255.255 > new_dhcp_lease_time=3D2813 > new_dhcp_message_type=3D5 > new_dhcp_rebinding_time=3D2363 > new_dhcp_renewal_time=3D1013 > new_dhcp_server_identifier=3D96.33.192.1 > new_domain_name_servers=3D'71.10.216.1 71.10.216.2' > new_interface_mtu=3D1500 > new_ip_address=3D71.15.253.203 > new_network_number=3D71.15.252.0 > new_routers=3D71.15.252.1 > new_subnet_cidr=3D22 > new_subnet_mask=3D255.255.252.0 > dhcpcd exited > =20 > =20 > And if I actually boot the machine that way (rather than run it in = test) I get only IpV4; the v6 solicitation never happens. =20 Don't use -T in the real world. It will exit once one address family comple= tes. You probably want the --noconfigure option. Roy
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1910419702c.f8dcf010456961.6536659919669261420>