From owner-freebsd-net@FreeBSD.ORG Sat May 17 15:25:24 2014 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 297CAE67 for ; Sat, 17 May 2014 15:25:24 +0000 (UTC) Received: from mail.ipfw.ru (mail.ipfw.ru [IPv6:2a01:4f8:120:6141::2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B0B5B2CE7 for ; Sat, 17 May 2014 15:25:23 +0000 (UTC) Received: from [2a02:6b8:0:401:222:4dff:fe50:cd2f] (helo=ptichko.yndx.net) by mail.ipfw.ru with esmtpsa (TLSv1:CAMELLIA256-SHA:256) (Exim 4.76 (FreeBSD)) (envelope-from ) id 1Wlca0-000PND-3e; Sat, 17 May 2014 15:15:04 +0400 Message-ID: <53777F09.5030000@FreeBSD.org> Date: Sat, 17 May 2014 19:23:53 +0400 From: "Alexander V. Chernikov" User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.0.1 MIME-Version: 1.0 To: Andreas Nilsson Subject: Re: Problem with ipfw table add 0.0.0.0/8 References: <5371084F.1060009@bsdinfo.com.br> <5371112B.2030209@bsdinfo.com.br> <5371E9E7.70400@smartspb.net> <5371F4C8.3080501@FreeBSD.org> <53720AA4.80909@smartspb.net> <537767C5.80205@FreeBSD.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.18 Cc: Dennis Yusupoff , FreeBSD Net , Marcelo Gondim X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 May 2014 15:25:24 -0000 On 17.05.2014 19:14, Andreas Nilsson wrote: > > > > On Sat, May 17, 2014 at 3:44 PM, Alexander V. Chernikov > > wrote: > > On 13.05.2014 16:05, Dennis Yusupoff wrote: > > I think that universal table for all kind of data (ipv4, ipv6, > ports, > etc) is a bad idea by design. At least unless you haven't any > ability to > > It is not always "universal" in kernel. > Actually, different radix tables are used to store both IPv4 and > IPv6 in single table. > > specify address family on add, to avoid attempts to guess what > user > meant. Something like "ipfw table X add DEEF.DE > ipv6". > > I'm going to add explicit table type/naming setup soon. > Idea is the following: > > 1) Existing table can be named and addressed by either number or name. > However, you still need to assign table number manually. > > 2) Table type/name can be specified explicitly via one of the > following commands: > * ipfw table 1 create [type ] [name > "table_name"] > * ipfw table name "table_name" > * ipfw table "table_name" type > > 3) ipfw(8) stops trying to guess appropriate type based on used > value. Instead, > it requests table type from kernel and interprets value according > to returned type. > Default type for all tables is cidr > > 4) Table(s) can be returned to default values using ipfw table > destroy. > Destroy means: > * flush > * table tries (or other structures) freed > * type set to cidr > > > > > > 13.05.2014 14:32, Alexander V. Chernikov пишет: > > On 13.05.2014 13:46, Dennis Yusupoff wrote: > > May be this will help? See answer on > http://www.freebsd.org/cgi/query-pr.cgi?pr=bin/189471 > > I'll try to fix it within a few days. > > Fixed in r266310. > > With all of these changes, would it be possible to get tablearg to > store ipv6 as well? I seem to remember it is 32bit only today. Well, I'd prefer not to increase tablearg directly. It is probably possible to implement some kind of "nexthop" table adds additional auto-filled nexthop array. > > Best regards > Andreas