From owner-freebsd-net@FreeBSD.ORG Mon Jun 17 20:37:48 2013 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 3E3185DB; Mon, 17 Jun 2013 20:37:48 +0000 (UTC) (envelope-from brian@freebsd.org) Received: from smtp-out-02.shaw.ca (smtp-out-02.shaw.ca [64.59.136.138]) by mx1.freebsd.org (Postfix) with ESMTP id F2F2D1E32; Mon, 17 Jun 2013 20:37:47 +0000 (UTC) X-Cloudmark-SP-Filtered: true X-Cloudmark-SP-Result: v=1.1 cv=YS95TUGYX+MRkNY/meip+CxRTyy2F4x7QGJ4HWfgHsg= c=1 sm=1 a=0Evk4HcnhGUA:10 a=dBRESv0yCI8A:10 a=BLceEmwcHowA:10 a=kj9zAlcOel0A:10 a=Jvqgub9IZPV2TmRqH1mFPg==:17 a=P4JvR0-YAAAA:8 a=g0wtaXY6AAAA:8 a=6I5d2MoRAAAA:8 a=uYfCM8JhAAAA:8 a=MMwg4So0AAAA:8 a=VkI5GP1dgp3jts2Rwu8A:9 a=CjuIK1q_8ugA:10 a=DWS6ea1utk0A:10 a=SV7veod9ZcQA:10 a=2joWEaGdj38A:10 a=WJ3hkfHDukgA:10 a=HpAAvcLHHh0Zw7uRqdWCyQ==:117 Received: from unknown (HELO gw.Awfulhak.org) ([174.7.169.46]) by smtp-out-02.shaw.ca with ESMTP; 17 Jun 2013 14:37:41 -0600 Received: from [10.10.11.20] ([96.53.48.10]) (authenticated bits=0) by gw.Awfulhak.org (8.14.7/8.14.7) with ESMTP id r5HKba0x061700 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Mon, 17 Jun 2013 13:37:37 -0700 (PDT) (envelope-from brian@FreeBSD.org) Subject: Re: Some routes no longer getting flagged with 'GATEWAY' in fbsd >=8 Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\)) Content-Type: text/plain; charset=us-ascii From: Brian Somers In-Reply-To: Date: Mon, 17 Jun 2013 13:37:36 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <5CD9527C-6B2E-42D9-A3F6-788522F6E14A@FreeBSD.org> References: <51BF591D.1050301@mackn.org> To: "Li, Qing" X-Mailer: Apple Mail (2.1508) X-Spam-Status: No, score=2.2 required=5.0 tests=RDNS_NONE,SPF_SOFTFAIL autolearn=no version=3.3.2 X-Spam-Level: ** X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on gw.lan.Awfulhak.org Cc: "freebsd-net@freebsd.org" , Mack Nagashima , "qingli@freebsd.org" X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Jun 2013 20:37:48 -0000 Also relevant is this patch.... http://patchwork.diac24.net/patch/494/mbox/ I guess it seems like more of a workaround than a fix though. On Jun 17, 2013, at 12:18 PM, "Li, Qing" wrote: > Hi, >=20 > I tried to keep the route messages to be legacy compatible due to = reported=20 > breakage at the time. Let me revisit the code and get back to you. >=20 > I haven't run the quagga code for years, so please don't mind me = request > some information from you offline. >=20 > --Qing >=20 >=20 > ________________________________________ > From: owner-freebsd-net@freebsd.org [owner-freebsd-net@freebsd.org] on = behalf of Mack Nagashima [freebsd@mackn.org] > Sent: Monday, June 17, 2013 11:44 AM > To: freebsd-net@freebsd.org > Subject: Some routes no longer getting flagged with 'GATEWAY' in fbsd = >=3D8 >=20 > we're in the process of upgrading from fbsd 7 to 9 and noticed a = change > in behavior that might be problematic for us. >=20 > We use quagga to establish bgp sessions with a router. We have it set > to redistribute kernel routes. > Zebra seems to drop anything that doesn't have the 'GATEWAY' flag set = on > a route. >=20 > Prior to fbsd8 this wasn't a problem. Doing something like the > following worked fine in fbsd7: >=20 > ifconfig em0 inet 192.168.100.1/24 > ifconfig lo0 inet 192.168.100.100/24 alias > route add -nostatic 192.168.100.100/32 192.168.100.1 >=20 > in fbsd7 this would yield a route with the flags = according > to RTM_GET. > in fbsd8+ the same would yield a route with without the GATEWAY = flag. >=20 > However the RTM_ADD for the 'route add' comes in with = > on fbsd8+ so quagga does add if it's up before the route gets added = but > starting quagga after the route is added ignores it since it's missing > the GATEWAY flag once in the routing table. (route delete also fails = to > propagate to quagga since the GATEWAY flag is missing) >=20 > I assume this is all due to the networking overhaul in fbsd8 and = perhaps > it no longer flags any route who's gateway is bound to ANY interface = on > the box as a gateway. >=20 > So the ultimate question is.. is there a way to get the legacy = behavior > and get them flagged with GATEWAY so zebra will see them or a better > solution with the way networking now works... (i noticed that issuing = a > 'route change' of an existing route with the GATEWAY flag set seems to > work as it doesn't drop the flag when the gateway changes under it...) >=20 > Thanks in advance! >=20 > -mackn >=20 -- Brian Somers = Don't _EVER_ lose your sense of humour ! =