Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 02 Oct 2006 17:19:12 +0900
From:      JINMEI Tatuya / =?ISO-2022-JP?B?GyRCP0BMQEMjOkgbKEI=?= <jinmei@isl.rdc.toshiba.co.jp>
To:        John Hay <jhay@meraka.org.za>
Cc:        freebsd-net@freebsd.org
Subject:   Re: ipv6 host routes
Message-ID:  <y7vwt7jcepr.wl%jinmei@isl.rdc.toshiba.co.jp>
In-Reply-To: <20060908161514.GA42016@zibbi.meraka.csir.co.za>
References:  <20060907100944.GA68587@zibbi.meraka.csir.co.za> <20060907141019.91998.qmail@web26604.mail.ukl.yahoo.com> <20060908161514.GA42016@zibbi.meraka.csir.co.za>

next in thread | previous in thread | raw e-mail | index | archive | help
>>>>> On Fri, 8 Sep 2006 18:15:14 +0200, 
>>>>> John Hay <jhay@meraka.org.za> said:

> With this and my FreeBSD/IPv6 port of olsrd I can run multiple wireless
> interfaces with the same IPv6 subnet and olsrd can make it all work.

I should have looked at it much earlier (sorry about the delay), but I
don't this change is correct.  This will easily bother statically
installed route (especially) on a point-to-point interface.

There seem to be some try-and-errors in the CURRENT branch, but even
the latest revision (1.69) has a bad side-effect.  For example, if you
statically install the following *host* route

# route add -inet6 2001:db8::abcd -host -interface gif0

the latest revision of kernel will eventually remove it due to
unreachability detection, which is unlikely what the administrator
wanted to see.

The key point here is whether the route is statically created or not.
And, if I understand your intent correctly, the host route you want to
install is not really "static" in that it can (or should) be removed
when it's detected to be unreachable, right?

If so, the correct change to the kernel is the patch attached below
(it's against RELENG_6 as of today, which is rev. 1.48.2.14).

					JINMEI, Tatuya
					Communication Platform Lab.
					Corporate R&D Center, Toshiba Corp.
					jinmei@isl.rdc.toshiba.co.jp

Index: nd6.c
===================================================================
RCS file: /home/ncvs/src/sys/netinet6/nd6.c,v
retrieving revision 1.48.2.14
diff -u -r1.48.2.14 nd6.c
--- nd6.c	20 Sep 2006 19:10:18 -0000	1.48.2.14
+++ nd6.c	2 Oct 2006 08:17:30 -0000
@@ -1315,7 +1315,7 @@
 		callout_init(&ln->ln_timer_ch, 0);
 
 		/* this is required for "ndp" command. - shin */
-		if (req == RTM_ADD) {
+		if (req == RTM_ADD && (rt->rt_flags & RTF_STATIC)) {
 		        /*
 			 * gate should have some valid AF_LINK entry,
 			 * and ln->ln_expire should have some lifetime
@@ -1392,8 +1392,6 @@
 					    ip6_sprintf(&llsol), error));
 				}
 			}
-		} else if (req == RTM_ADD && SDL(gate)->sdl_alen == 0) {
-			ln->ln_state = ND6_LLINFO_INCOMPLETE;
 		}
 		break;
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?y7vwt7jcepr.wl%jinmei>