[Dnsmasq-discuss] dhcp-pd, and autoassigned internal interfaces issues

Dave Taht dave.taht at gmail.com
Tue Jan 21 16:19:06 GMT 2014


I have finally got my first-ever comcast ipv6 set of users up, and we
have a problem
with the interrelationship between addresses assigned dynamically by
dhcpv6-pd and other means in dnsmasq 2.68.

What happens now is that dhcpv6-pd works but dnsmasq 2.68 filters out the
interface

13: sw00: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000
    inet6 2601:X:Y:9a1::1/64 scope global dynamic
       valid_lft 182420sec preferred_lft 182420sec

so sends no ras.

adding a second "stable" interface dnsmasq picks up.


    inet6 2601:3:8180:9a1::2/64 scope global
       valid_lft forever preferred_lft forever


this check was not in dnsmasq 2.66, and was put in later for fairly
sound reasons
(like you don't want to start serving RAs on a SLAAC assigned
address), but in the
dhcp-pd case or otherwise assigned by the router (6in4) case, we do.

Anyway the below patch "fixes it" but I'd like there to be some clear indicator
of where things came from somehow.

>From 4f55df81d69d20230e18c90d772904372b2b90a4 Mon Sep 17 00:00:00 2001
>From: Jonas Gorski <XXXXX at openwrt.org>
>Date: Wed, 8 Jan 2014 11:55:08 +0100
>Subject: [PATCH] allow dhcp range construction with non-permanent addresses

The linux kernel treats all addresses with a limited lifetime as being
non permanent, but when taking over the prefix livetimes from upstream
assigned prefixes through DHCP, addresses will always have a limited
lifetime.

Still reject temporary addresses, as they indicate autoconfigured
interfaces.

Contributed by T-Labs, Deutsche Telekom Innovation Laboratories

Signed-off-by: Jonas Gorski <jogo at openwrt.org>
---
 src/netlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/netlink.c b/src/netlink.c
index 3be94ee..d5de4ab 100644
--- a/src/netlink.c
+++ b/src/netlink.c
@@ -265,7 +265,7 @@ int iface_enumerate(int family, void *parm, int
(*callback)())
     if (ifa->ifa_flags & IFA_F_DEPRECATED)
       flags |= IFACE_DEPRECATED;

-    if (ifa->ifa_flags & IFA_F_PERMANENT)
+    if (!(ifa->ifa_flags & IFA_F_TEMPORARY))
       flags |= IFACE_PERMANENT;

     if (addrp && callback_ok)


-- 
Dave Täht

Fixing bufferbloat with cerowrt: http://www.teklibre.com/cerowrt/subscribe.html



More information about the Dnsmasq-discuss mailing list