From owner-freebsd-net@FreeBSD.ORG Wed Nov 10 16:14:28 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 12DAC16A4CE for ; Wed, 10 Nov 2004 16:14:28 +0000 (GMT) Received: from vbook.fbsd.ru (asplinux.ru [195.133.213.194]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7258B43D3F for ; Wed, 10 Nov 2004 16:14:27 +0000 (GMT) (envelope-from vova@vbook.fbsd.ru) Received: from vova by vbook.fbsd.ru with local (Exim 4.43 (FreeBSD)) id 1CRv6w-0001a5-IX; Wed, 10 Nov 2004 19:14:18 +0300 From: Vladimir Grebenschikov To: Sean Chittenden In-Reply-To: <29838DF3-3326-11D9-A34C-000A95C705DC@chittenden.org> References: <7070775A-331F-11D9-A34C-000A95C705DC@chittenden.org> <20041110140554.GN98623@cicely12.cicely.de> <29838DF3-3326-11D9-A34C-000A95C705DC@chittenden.org> Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: quoted-printable Organization: SWsoft Date: Wed, 10 Nov 2004 19:14:17 +0300 Message-Id: <1100103257.977.27.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.0.0FreeBSD GNOME Team Port Sender: Vladimir Grebenschikov cc: ticso@cicely.de cc: freebsd-net Subject: Re: Ability to live lock 5.3 via routing... X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: vova@fbsd.ru List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Nov 2004 16:14:28 -0000 =F7 =D3=D2, 10/11/2004 =D7 06:38 -0800, Sean Chittenden =D0=C9=DB=C5=D4: > >> Pretty easy for me to reproduce. The machine live locks so I can't=20 > >> get > >> anything out of it, serial console or otherwise. :( Imagine a=20 > >> machine > >> with two NICs, fxp0 and fxp1 (though it could be any two NICs). The > >> following commands should lead to a lock: > >> > >> # Add the primary address on the external NIC > >> ifconfig fxp0 192.168.1.2 netmask 255.255.255.0 media 100baseTX > >> mediaopt full-duplex > >> > >> # Add the default gateway > >> route add default 192.168.1.1 > >> > >> # Add a network to the internal interface > >> ifconfig fxp1 10.10.10.1 netmask 255.255.255.0 media 100baseTX=20 > >> mediaopt > >> full-duplex > >> > >> # On the external interface, on the same VLAN, there are two other > >> networks. > >> # Add aliases that way the machine can participate on those networks. > >> ifconfig fxp0 alias 192.168.2.250 netmask 255.255.255.255 > >> ifconfig fxp0 alias 192.168.3.250 netmask 255.255.255.255 > > > > You should use the correct netmask for the networks: > > e.g.: > > ifconfig fxp0 alias 192.168.2.250 netmask 255.255.255.0 > > or: > > ifconfig fxp0 alias 192.168.2.250/24 > > /32 is only correct if you are adding an alias for a network you > > already participate. >=20 > *grabs pointy hat* You're right, I knew better. When using the=20 > correct netmasks to the interface aliases, everything works without a=20 > hitch. Forgot to change the netmasks when "evolving" this particular=20 > mess of subnets and fired off an inquiry. Still, setting /32's and=20 > designating routes that hang off of a host address works (and=20 > rightfully it should) until that third route is added, then everything=20 > goes apeshit. Regardless, thanks for the obvious fix... still not sure=20 > why it does this though. If someone doesn't pick it up in the next=20 > week, I'll file a PR so it doesn't get lost. -sc Actually your actions should not lead to lockup anyway. It is possible to add interface route even if you have no address on this subnet, please try: route add -net 192.168.2.0/24 -iface fxp0 -cloning route add -net 192.168.3.0/24 -iface fxp0 -cloning but anyway, you should not point by routes to yourself --=20 Vladimir B. Grebenchikov vova@fbsd.ru