kern/71474: route lookup does not skip interfaces marked down
Ruslan Ermilov
ru at FreeBSD.org
Tue Sep 7 23:30:31 PDT 2004
The following reply was made to PR kern/71474; it has been noted by GNATS.
From: Ruslan Ermilov <ru at FreeBSD.org>
To: Thomas Quinot <thomas at cuivre.fr.eu.org>
Cc: bug-followup at 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 at 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/--
More information about the freebsd-bugs
mailing list