From owner-freebsd-net Tue Jul 3 6:54:36 2001 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 51D5E37B401; Tue, 3 Jul 2001 06:54:31 -0700 (PDT) (envelope-from tbyte@tbyte.org) Received: from localhost (localhost [127.0.0.1]) by shadow.otel.net (8.11.4/8.11.1) with ESMTP id f63DsTK35863; Tue, 3 Jul 2001 16:54:30 +0300 (EEST) (envelope-from tbyte@tbyte.org) Date: Tue, 3 Jul 2001 16:54:29 +0300 (EEST) From: Iasen Kostoff X-Sender: tbyte@shadow.otel.net To: Ruslan Ermilov Cc: freebsd-net@FreeBSD.ORG Subject: Re: adding a route to host via interface In-Reply-To: <20010703162556.E39090@sunbay.com> Message-ID: 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 On Tue, 3 Jul 2001, Ruslan Ermilov wrote: > On Tue, Jul 03, 2001 at 03:34:14PM +0300, Iasen Kostoff wrote: > > > > > > On Tue, 3 Jul 2001, Ruslan Ermilov wrote: > > > > > On Tue, Jul 03, 2001 at 02:30:48PM +0300, Iasen Kostoff wrote: > > > > > > > > > > > > On Tue, 3 Jul 2001, Ruslan Ermilov wrote: > > > > > > > > > On Mon, Jul 02, 2001 at 05:40:07PM +0300, Iasen Kostoff wrote: > > > > > > > > > > > > Problem is that adding a route to host throw interface adds > > > > > > inerface as gateway (iface's lladdr). And you should manualy change lladdr > > > > > > of this route to the real lladdr. > > > > > > > > > > > > this is it: > > > > > > > > > > > > route add -host foo -iface bar > > > > > > arp -s foo real_lladdr_of_foo > > > > > > > > > > > > Is that realy a problem or I'm missing something ? > > > > > > > > > > > Try this: > > > > > > > > > > route add -host foo -link bar:real_lladdr_of_foo -llinfo -interface > > > > > > > > > But if I don't know the lladdr - because now I should use tcpsump(1) with > > > > -i iface -e to see the lladdr of the client and when they change their GW > > > > computer or its Lan card I should do that again (and if am not around they > > > > don't have inet ofcourse) but if they are connected on cisco router that > > > > do not hapen because I'm not routing to lladdr but throw iface. > > > > > > > > Can that be fixed some how ? > > > > > > > I apparently lost the context here. What are you trying to do? > > > You want the host ``foo'' to be resolved through ARP? If that > > > is the case, this is somewhat tricky, but still possible: > > > > > > route add foo/32 -iface bar -cloning > > > > > > > > I tried - route add foo -iface bar -cloning and it didin't work ofcourse :). > > > Yup, should be ``arp: couldn't allocate llinfo for rt''. > > > I think route(8) or /sys/net/route.c should reject that kind of route. > > I tried to set or convert it to -net route - foo/32(I think the second way is > > better, what you think ?). > > > You can't change host route to network route, or vise versa; destination > is the Patricia's tree key, and it can't be changed. The only possible > way is like I suggested: ``route add foo/32 -iface bar -cloning''. Yes I know, but ``route add foo -iface bar -cloning`` is meanless, I think, because host route could not be cloned and I kernel should auto set foo to foo/32 because of meanlessness of -host foo. And is route add -host foo -iface bar (without -cloning) could be used for something ? > > > You still did not tell me what are you trying to do. :-) > > I'm trying to make routing on FreeBSD as easier and streight forward as it is in cisco's routers(and may be better). :-) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message