From owner-freebsd-net@FreeBSD.ORG Tue Sep 1 06:51:32 2009 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 71AD2106566C for ; Tue, 1 Sep 2009 06:51:32 +0000 (UTC) (envelope-from cjeker@diehard.n-r-g.com) Received: from diehard.n-r-g.com (diehard.n-r-g.com [62.48.3.9]) by mx1.freebsd.org (Postfix) with ESMTP id E2C498FC2A for ; Tue, 1 Sep 2009 06:51:31 +0000 (UTC) Received: (qmail 17798 invoked by uid 1001); 1 Sep 2009 06:24:50 -0000 Date: Tue, 1 Sep 2009 08:24:50 +0200 From: Claudio Jeker To: freebsd-net@freebsd.org Message-ID: <20090901062449.GC25711@diehard.n-r-g.com> Mail-Followup-To: Claudio Jeker , freebsd-net@freebsd.org References: <4A9C137C.7020303@elischer.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) Subject: Re: [patch] Unbreak setfib + routing daemons 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: Tue, 01 Sep 2009 06:51:32 -0000 On Mon, Aug 31, 2009 at 07:48:32PM +0000, Stef Walter wrote: > Julian Elischer wrote: > > there are two ways to go with this one being what you have done teh > > other to add fib info to the messages, Apparently > > OpenBSD has implemented the second by re-using a disused field. > > (I'm ve only been told this second hand) > > It seems like they've taken apart the rtm_flags field (int), and > repurposed it as rtm_tableid (u_short), rtm_priority (u_char) and padding. > This is not 100% correct. rtm_flags is still there. We changed the structure of the routing messages some time ago and added the necessary additional fields while doing that. This included a bump in rtm_version and a simple recompile of third party routing daemons like quagga was enough. > Obviously such a change would require patches to the various routing > daemons as well. But if you think this is the only way forward (ie: > filtering the messages in userland), I'd be happy to contribute. > I plan to extend our routing socket filters to include the tableid making it possible to limit the messages to only that part needed. Getting all messages from all routing domains into all PF_ROUTE listeners results in unneeded overhead. -- :wq Claudio