From owner-freebsd-net@FreeBSD.ORG Thu Oct 25 01:29:44 2007 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 67AA616A419 for ; Thu, 25 Oct 2007 01:29:44 +0000 (UTC) (envelope-from liujiusheng@galaxywind.com) Received: from m15.cnsun.net (m15.cnsun.net [210.22.15.15]) by mx1.freebsd.org (Postfix) with ESMTP id 2702313C48A for ; Thu, 25 Oct 2007 01:29:42 +0000 (UTC) (envelope-from liujiusheng@galaxywind.com) Received: from KsemailAntiServer-Engine-5.0-Build-050315-localhost (m15.cnsun.net [127.0.0.1]) by m15.cnsun.net (CnSunMail_NC http://www.51.hk) with SMTP id 1F6795BEFFC; Thu, 25 Oct 2007 09:39:35 +0800 (CST) Received: from [127.0.0.1] (unknown [222.210.203.91]) by m15.cnsun.net (CnSunMail_NC http://www.51.hk) with ESMTP id A2A905BEF93; Thu, 25 Oct 2007 09:39:32 +0800 (CST) Message-ID: <471FF1AC.4000800@galaxywind.com> Date: Thu, 25 Oct 2007 09:30:20 +0800 From: LiuJiusheng User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: gurney_j@resnet.uoregon.edu, freebsd-net@freebsd.org References: <471EF736.1070207@galaxywind.com> <20071024185610.GE39759@funkthat.com> In-Reply-To: <20071024185610.GE39759@funkthat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Subject: Re: Routing problems 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: Thu, 25 Oct 2007 01:29:44 -0000 John-Mark Gurney wrote: > LiuJiusheng wrote this message on Wed, Oct 24, 2007 at 15:41 +0800: > >> Hello all: >> I have found something interesting in FreeBSD routing. This is a test environment, which is not used in reality(perhaps meaningless). >> >> | host |-------| router1 |----------| router2 | >> 2.2.2.2 2.2.2.1 6.6.6.1 6.6.6.2 X.X.X.X >> (All run FreeBSD OS) >> >> Two routes is added to the router1. (4.4.4.0/24 6.6.6.2) and (6.6.6.0/24 2.2.2.2).Then the routing table look this: >> Destination Gateway Flags Refs Use Netif Expire >> 2 link#3 UC 0 0 >> 2.2.2.1 00:0c:29:67:a5:88 UHLW 0 4 >> 2.2.2.2 00:09:6b:42:94:b7 UHLW 1 2 1068 >> 4.4.4/24 6.6.6.2 UGS 0 38 >> 6 link#4 UC 0 0 >> 6.6.6/24 2.2.2.2 UGS 1 0 >> >> At this time, route 4.4.4.0 can not be used. When ping 4.4.4.4, the machine prints: sent to: Invalid argument. If I remove the route 6.6.6.0/24, then all become correct. >> > > You need to have the gateway for 4.4.4/24 be 2.2.2.2... The routing > code isn't smart enough to follow the trail through 6.6.6/24 to get to > 2.2.2.2.... > > Linux takes 6.6.6.2 as gateway for route 4.4.4/24. But some Oses have the gateway 2.2.2.2. (treat 4.4.4/24 as a recursive route). Is there any standard for this?