From owner-freebsd-net@FreeBSD.ORG Tue Apr 6 05:28:46 2004 Return-Path: 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 D661F16A4CE; Tue, 6 Apr 2004 05:28:46 -0700 (PDT) Received: from mailhost.packetfront.com (mailhost.packetfront.com [212.247.6.194]) by mx1.FreeBSD.org (Postfix) with ESMTP id 177F243D5A; Tue, 6 Apr 2004 05:28:46 -0700 (PDT) (envelope-from anders.lowinger@packetfront.com) Received: from [212.247.6.198] (helo=maillab.packetfront.com) by mailhost.packetfront.com with esmtp (Exim 3.35 #1 (Debian)) id 1BApWs-0004Hw-00; Tue, 06 Apr 2004 14:18:10 +0200 Received: from packetfront.com (unknown [192.168.1.173]) by maillab.packetfront.com (Postfix) with ESMTP id 9865D73BDB; Tue, 6 Apr 2004 14:27:52 +0200 (CEST) Message-ID: <4072A169.9010206@packetfront.com> Date: Tue, 06 Apr 2004 14:24:09 +0200 From: Anders Lowinger User-Agent: Mozilla Thunderbird 0.5 (Windows/20040207) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Andre Oppermann References: <20040331005914.A6934@xorpc.icir.org> <40712A8F.9000704@packetfront.com> <40716208.808CF084@freebsd.org> <4072916D.101@packetfront.com> <40729B7A.2C984BD3@freebsd.org> In-Reply-To: <40729B7A.2C984BD3@freebsd.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: Luigi Rizzo cc: net@freebsd.org Subject: Re: do we support non contiguous netmasks ? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 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, 06 Apr 2004 12:28:47 -0000 Andre Oppermann wrote: >> interface ethernet 0 >> ip address 192.168.0.0 mask 255.255.253.0 > > This is simply a supernet (aka classless) but *not* a non-contignous > netmask. A non-contignous netmask would look like 255.254.255.0. Nope, 255.255.253.0 binary is 11111111.11111111.11111101.00000000 which is non-contignous. >> interface ethernet 0 >> ip address 192.168.0.0 mask 255.255.255.0 >> ip address 192.168.2.0 mask 255.255.255.0 secondary >> >>which gives the same functionality with contigious netmasks. > > Not really. Agree, not exactly the same > With the your second example hosts on the network have > to have different default gateways (192.168.0.1 and 192.168.2.1) > depending in which network range they are. In your first example > you just have one default gateway for all of them. However the > netmask has to match on all hosts otherwise you run into all sorts > of wierd trouble. In this case, the above is normally only used during a migration phase (as I mentioned, this is the only use of non-contignous i've seen, joining two separate subnets), so the hosts already have the correct default-route in their subnet. Hosts could optionally then be migrated to a common subnet. /Anders