From owner-freebsd-questions@FreeBSD.ORG Tue Apr 29 10:26:59 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 446D337B401 for ; Tue, 29 Apr 2003 10:26:59 -0700 (PDT) Received: from mail.uk.hybyte.net (mail.uk.hybyte.net [213.86.56.137]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF6BF43FA3 for ; Tue, 29 Apr 2003 10:26:58 -0700 (PDT) (envelope-from atrull@mail.uk.hybyte.net) Received: by mail.uk.hybyte.net (Postfix, from userid 1001) id 12EC6EB2D6; Tue, 29 Apr 2003 18:26:57 +0100 (BST) Date: Tue, 29 Apr 2003 18:26:57 +0100 From: Alex Trull To: Steve Warwick Message-ID: <20030429172657.GA62328@mail.uk.hybyte.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.1i cc: freebsd-questions@FreeBSD.ORG Subject: Re: Netmasks: the truth is out there? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Apr 2003 17:26:59 -0000 * Steve Warwick [2003-04-29 10:03:02 -0700]: > Hi All, > > I know someone out there knows the truth about netmasks. All the > documentation I can find on the net talks about "masking off" part of the IP > address and how you can tell network from subnet and host ids. > > However, I have knowledgeable friend who is telling me that the netmask is > also dependant on how the hosting company has set up their routing tables > and incorrect netmasking on my part can reduce or halt my connection. > > So the question is, who is right? Is it as simple as just masking off the > first three octets or does the netmask interact with the router? > > Please point me to an authoritative source or if you have the time, a brief > description of if or how the netmask has to match the router, as I am not > sure what questions to ask my hosting company. > > > --- > > My current rc.conf entry looks like this (these ips are bogus) - no > broadcast and FreeBSD seems happy with this. > > defaultrouter="123.456.789.1" > ifconfig_rl0="inet 123.456.789.111 netmask 255.255.240.0" > ifconfig_rl0_alias0="inet 123.456.789.112 netmask 255.255.255.0" > <+7 other aliases> > > Thoughts, suggestions, links ? Well, I can't help you with the theory. But I've seen a mistake in the rc.conf cutting you spamme: ifconfig_rl0_alias0="inet 123.456.789.112 netmask 255.255.255.0" should read: ifconfig_rl0_alias0="inet 123.456.789.112 netmask 255.255.255.255" as should any other secondary aliases to subordinate a prime address (where they would in reality share the same netmask) to nail the concept home, if you had another set of aliases for a different network: ifconfig_rl0_alias15="inet 321.456.987.11 netmask 255.255.240.0" ifconfig_rl0_alias16="inet 321.456.987.12 netmask 255.255.255.255" ifconfig_rl0_alias17="inet 321.456.987.13 netmask 255.255.255.255" ..... I hope that helps, and you find answers to your other questions. Cheers, Alex Trull Systems and Network Administrator & Information Commissioner C : +44 (0) 7966 203990 | Hybyte Solutions & Services Ltd D : +44 (0) 2079 764219 | 114-116 Rochester Row S : +44 (0) 2079 764200 | Victoria, London F : +44 (0) 2079 764229 | SW1P 1JQ http://mail.uk.hybyte.net/~atrull/pgppub.key