From owner-freebsd-net@FreeBSD.ORG Sun Oct 1 00:45:29 2006 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C2E4616A403 for ; Sun, 1 Oct 2006 00:45:29 +0000 (UTC) (envelope-from sec@42.org) Received: from ice.42.org (ice.42.org [194.77.85.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 39E3443D4C for ; Sun, 1 Oct 2006 00:45:29 +0000 (GMT) (envelope-from sec@42.org) Received: by ice.42.org (Postfix, from userid 1000) id D56F2C490; Sun, 1 Oct 2006 02:45:27 +0200 (CEST) Date: Sun, 1 Oct 2006 02:45:27 +0200 From: Stefan `Sec` Zehl To: freebsd-net@freebsd.org Message-ID: <20061001004527.GA8387@ice.42.org> X-Current-Backlog: 2575 messages Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.1i I-love-doing-this: really X-Modeline: vim:set ts=8 sw=4 smarttab tw=72 si noic notitle: Accept-Languages: de, en X-URL: http://sec.42.org/ Subject: ipv6 and magically vanishing routes via gif0 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Oct 2006 00:45:29 -0000 Hi, I just upgraded from FreeBSD-5 to -6, and now my default route via gif0 vanishes after 7 seconds. | ice:~#ifconfig gif0 | gif0: flags=8051 mtu 1280 | tunnel inet 194.77.85.2 --> 193.149.44.208 | inet6 fe80::20e:a6ff:fe04:ea37%gif0 prefixlen 64 scopeid 0x14 | inet6 2001:608:9::1 prefixlen 128 | | ice:~#route add -inet6 default -interface gif0 | add net default: gateway gif0 | | ice:~#ping6 www.kame.net | PING6(56=40+8+8 bytes) 2001:608:9::1 --> 2001:200:0:8002:203:47ff:fea5:3085 | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=0 hlim=42 time=343.451 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=1 hlim=45 time=349.477 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=2 hlim=45 time=349.689 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=3 hlim=42 time=342.212 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=5 hlim=42 time=342.123 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=6 hlim=45 time=348.703 ms | 16 bytes from 2001:200:0:8002:203:47ff:fea5:3085, icmp_seq=7 hlim=45 time=348.479 ms | ping6: sendmsg: No route to host | ping6: wrote www.kame.net 16 chars, ret=-1 In fact, any route '-interface gif0' will vanish 7 seconds after the first packet via that link. After some wild guesses, I found out, that ndp seems to be the culprit here. -- If I disable ndp on gif0 with | ice:~#ndp -i gif0 -- -nud | linkmtu=0, maxmtu=1280, curhlim=64, basereachable=30s0ms, reachable=18s, retrans=1s0ms | Flags: accept_rtadv Then the routing table stays as it should. The question is, am I missing something here? Can anybody reproduce that problem? It seems wrong that the kernel would delete static routes without even a single log message. Furthermore I find it kind of strange that there is neighbour discovery happening at all on an tunnel interface. My v6 relevant config: | ipv6_enable="YES" | ipv6_network_interfaces="vr0 lo0 gif0" | ipv6_ifconfig_vr0="2001:608:9:42:: eui64" | ipv6_ifconfig_vr0_alias0="2001:608:9::42/128" | ipv6_ifconfig_vr0_alias0="fec0::35/128" # Site-local DNS | ipv6_ifconfig_gif0="2001:608:9::1/128" | | ipv6_defaultrouter="-interface gif0" | | ipv6_gateway_enable="YES" | rtadvd_enable="YES" | rtadvd_interfaces="vr0" | | myhostip="194.77.85.2" | gif_interfaces="gif0" | gifconfig_gif0="$myhostip 193.149.44.208" CU, Sec -- The facts, although interesting, are irrelevant.