From owner-freebsd-net Wed Jun 5 4:24: 3 2002 Delivered-To: freebsd-net@freebsd.org Received: from ShadoW.OTEL.net (JuDiCaToR.OTEL.net [212.36.9.113]) by hub.freebsd.org (Postfix) with ESMTP id F3E8F37B401 for ; Wed, 5 Jun 2002 04:23:58 -0700 (PDT) Received: from ikostov (helo=localhost) by ShadoW.OTEL.net with local-esmtp (Exim 3.36 #1) id 17FYtP-000LVF-00 for freebsd-net@freebsd.org; Wed, 05 Jun 2002 14:23:55 +0300 Date: Wed, 5 Jun 2002 14:23:55 +0300 (EEST) From: Iasen Kostov To: freebsd-net@freebsd.org Subject: host routes for interface addresses Message-ID: <20020605134856.R82177-100000@shadowhand.OTEL.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Hi, Some times I don't need addition of host route when I'm setting iface's address like in this case : xl0: flags=8943 mtu 1500 options=3 inet 212.36.9.113 netmask 0xfffffe00 broadcast 212.36.9.255 ether 00:04:76:1b:cb:72 media: Ethernet autoselect (100baseTX ) status: active xl1: flags=8843 mtu 1500 options=3 inet 212.36.9.113 netmask 0xffffffff broadcast 212.36.9.113 ether 00:50:da:5b:b2:64 media: Ethernet autoselect (100baseTX ) status: active xl2: flags=8843 mtu 1500 options=3 inet 212.36.9.113 netmask 0xffffffff broadcast 212.36.9.113 ether 00:04:76:22:16:92 media: Ethernet autoselect (10baseT/UTP) status: active xl3: flags=8843 mtu 1500 options=3 inet 212.36.9.113 netmask 0xffffffff broadcast 212.36.9.113 ether 00:04:76:22:16:97 media: Ethernet autoselect (none) status: no carrier xl4: flags=8843 mtu 1500 options=3 inet 212.36.9.113 netmask 0xffffffff broadcast 212.36.9.113 ether 00:10:4b:b8:65:2c media: Ethernet autoselect (10baseT/UTP) status: active xl5: flags=8843 mtu 1500 options=3 inet 212.36.9.113 netmask 0xffffffff broadcast 212.36.9.113 ether 00:04:76:22:15:83 media: Ethernet autoselect (100baseTX) status: active It works fine (just a warrning) with 4.4 kernel and before, but in 4.5 there is a check for host route addition and if it fail to add a route it also fails to set iface address (ofcourse I've patch it for myself). I need this not just for saving IPs but it's somewhat easier to route just throw iface i not to care about iface IPs. And something more, You know that the router has 1 IP and thats it , don't care on which iface Your are connected right now, it has 1 IP and thats your gateway. This scheme looks a bit like Cisco's "ip unnumbered" interfaces and I don't think it's a bad idea. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message