From owner-freebsd-questions@FreeBSD.ORG Wed Nov 10 18:30:56 2004 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 0C80D16A4CE for ; Wed, 10 Nov 2004 18:30:56 +0000 (GMT) Received: from mail3.speakeasy.net (mail3.speakeasy.net [216.254.0.203]) by mx1.FreeBSD.org (Postfix) with ESMTP id B9EA243D2F for ; Wed, 10 Nov 2004 18:30:55 +0000 (GMT) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: (qmail 18119 invoked from network); 10 Nov 2004 18:30:55 -0000 Received: from dsl092-078-145.bos1.dsl.speakeasy.net (HELO be-well.ilk.org) ([66.92.78.145]) (envelope-sender ) by mail3.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 10 Nov 2004 18:30:55 -0000 Received: by be-well.ilk.org (Postfix, from userid 1147) id BEFB411; Wed, 10 Nov 2004 13:30:54 -0500 (EST) Sender: lowell@be-well.ilk.org To: Sean Peisert References: <20041110025713.19468.qmail@web90102.mail.scd.yahoo.com> From: Lowell Gilbert Date: 10 Nov 2004 13:30:54 -0500 In-Reply-To: <20041110025713.19468.qmail@web90102.mail.scd.yahoo.com> Message-ID: <44fz3h1rq9.fsf@be-well.ilk.org> Lines: 28 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii cc: freebsd-questions@freebsd.org Subject: Re: Two NICs with one IP address each on the same subnet X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: freebsd-questions@freebsd.org List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Nov 2004 18:30:56 -0000 Sean Peisert writes: > I have a FreeBSD 5.x box with two NICs that I'd like > to set up on the same subnet. The purpose is to run > separate services on each NIC. I have the box set up > with my rc.conf containing the following lines: > > defaultrouter="..." > hostname="..." > ifconfig_xl0="inet ... netmask 255.255.255.224" > ifconfig_sk0="inet ... netmask 255.255.255.224 mtu > 9000" > > The router and IP addresses are all on the same > subnet, as I previously mentioned. Unfortunately, the > first IP address seems not to work (I can ssh to the > second, but not the first). Is there something > special I need to do to the routing to get this to > work? Anything to the kernel? First of all, there's no reason to do this on a separate NIC. Just use one and put an alias on it for the second address. And secondly, it should be obvious that you can't really have two different routes to that subnet. [so use an all-ones mask with one of the addresses] -- Lowell Gilbert, embedded/networking software engineer, Boston area http://be-well.ilk.org:8088/~lowell/