[PATCH]: The 6to4 stf0 interface flapping in/out of tentative in FreeBSD 11
Andrey V. Elsukov
bu7cher at yandex.ru
Fri Jun 22 18:20:17 UTC 2018
On 22.06.2018 21:08, Viktor Dukhovni wrote:
>> Your change looks reasonable due to IPv6 DAD procedure does check for
>> presence of IFF_DRV_RUNNING flag. But actually it seems the right
>> solution should be disabling DAD for if_stf(4) interface.
>> IPv6 DAD requires that given interface should be multicast capable, but
>> for if_stf(4) it is not true.
>> Will it help if you use `ifconfig stf0 inet6 no_dad` before assigning
>> IPv6 address?
>
> stf_up() in /etc/rc.d/stf has:
>
> ifconfig stf0 create >/dev/null 2>&1
> ifconfig stf0 inet6 2002:${ipv4_in_hexformat}:${stf_interface_ipv6_slaid:-0}:${stf_interface_ipv6_ifid} \
> prefixlen ${stf_prefixlen}
>
> Are you suggesting to add the:
>
> ifconfig stf0 inet6 no_data
Yes, but "no_dad", not "no_data".
> right under "ifconfig stf0 create"? I'd have to find a convenient time to
> reboot to the stock kernel, so this will take O(12 hours) before I can re-test.
>
> Perhaps the fix should be belt-and-suspenders? Both set IFF_DRV_RUNNING
> and disable DAD automatically for lack of multicast support? Setting
> the flag bit might avoid other future issues. Avoiding needless DAD
> polling sounds sensible.
We have already one tweak for if_stf(4) in in6_ifattach(), that disables
automatic LLA creation. I think we can also add disabling DAD there.
Something like:
Index: in6_ifattach.c
===================================================================
--- in6_ifattach.c (revision 335361)
+++ in6_ifattach.c (working copy)
@@ -683,6 +683,7 @@ in6_ifattach(struct ifnet *ifp, struct ifnet *alti
* it is rather harmful to have one.
*/
ND_IFINFO(ifp)->flags &= ~ND6_IFF_AUTO_LINKLOCAL;
+ ND_IFINFO(ifp)->flags |= ND6_IFF_NO_DAD;
break;
default:
break;
--
WBR, Andrey V. Elsukov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 553 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-net/attachments/20180622/212d4367/attachment.sig>
More information about the freebsd-net
mailing list