From owner-freebsd-bugs@FreeBSD.ORG Wed Sep 8 06:30:31 2004 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7475B16A4CE for ; Wed, 8 Sep 2004 06:30:31 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4EF2243D1F for ; Wed, 8 Sep 2004 06:30:31 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.11/8.12.11) with ESMTP id i886UVaR024846 for ; Wed, 8 Sep 2004 06:30:31 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.11/8.12.11/Submit) id i886UVfb024840; Wed, 8 Sep 2004 06:30:31 GMT (envelope-from gnats) Date: Wed, 8 Sep 2004 06:30:31 GMT Message-Id: <200409080630.i886UVfb024840@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Ruslan Ermilov Subject: Re: kern/71474: route lookup does not skip interfaces marked down X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Ruslan Ermilov List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Sep 2004 06:30:31 -0000 The following reply was made to PR kern/71474; it has been noted by GNATS. From: Ruslan Ermilov To: Thomas Quinot Cc: bug-followup@FreeBSD.org Subject: Re: kern/71474: route lookup does not skip interfaces marked down Date: Wed, 8 Sep 2004 09:24:51 +0300 --Ns7jmDPpOpCD+GE/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 07, 2004 at 08:44:24PM +0200, Thomas Quinot wrote: >=20 > This issue can be demonstrated using gif interfaces: >=20 > # ifconfig gif0 create > # ifconfig gif0 192.168.0.254 192.168.0.1 > # ifconfig gif0 down > # ifconfig gif1 create > # ifconfig gif1 192.168.0.253 192.168.0.1 >=20 > Note at this point that 192.168.0.1 is reachable through interface > gif1. >=20 > # route add 192.168.1.0 192.168.0.1 > # netstat -rn | grep 192.168 > 192.168.0.1 192.168.0.253 UH 1 0 gif1 > 192.168.1 192.168.0.1 UGS 0 0 gif0 >=20 > Note then that, even though 192.168.0.1 is marked as reachable through > gif1, for the purpose of routing to 192.168.1.0 the selected interface > is gif0 (which is down). >=20 > Fix not determined yet. This problem can be worked around by > changing the addresses on the down interface so it won't clash > with those of the up one: >=20 > # ifconfig gif0 192.168.99.1 192.168.99.2 > # ifconfig gif0 down > # route delete 192.168.1.0 192.168.0.1 > # route add 192.168.1.0 192.168.0.1 > # netstat -rn | grep 192.168 > 192.168.0.1 192.168.0.253 UH 1 0 gif1 > 192.168.1 192.168.0.1 UGS 0 0 gif1 >=20 Just tell it the interface you really want: route add -net 192.168.1 -iface gif1 Cheers, --=20 Ruslan Ermilov ru@FreeBSD.org FreeBSD committer --Ns7jmDPpOpCD+GE/ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (FreeBSD) iD8DBQFBPqWzqRfpzJluFF4RAiCTAJ0eXR3W+/fByp/PJJYkmUAOyzss3wCZAabP MZC2/HN4y8E4I5Ntz+KdMt0= =Amdw -----END PGP SIGNATURE----- --Ns7jmDPpOpCD+GE/--