From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 14 13:06:21 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 03ABF16A4CE; Wed, 14 Jan 2004 13:06:21 -0800 (PST) Received: from rwcrmhc13.comcast.net (rwcrmhc13.comcast.net [204.127.198.39]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6382743D60; Wed, 14 Jan 2004 13:06:06 -0800 (PST) (envelope-from cristjc@comcast.net) Received: from blossom.cjclark.org (c-24-6-186-224.client.comcast.net[24.6.186.224]) by comcast.net (rwcrmhc13) with ESMTP id <2004011421060501500blcice>; Wed, 14 Jan 2004 21:06:05 +0000 Received: from blossom.cjclark.org (localhost. [127.0.0.1]) by blossom.cjclark.org (8.12.9p2/8.12.8) with ESMTP id i0EL6443049194; Wed, 14 Jan 2004 13:06:04 -0800 (PST) (envelope-from cristjc@comcast.net) Received: (from cjc@localhost) by blossom.cjclark.org (8.12.9p2/8.12.9/Submit) id i0EL63TH049193; Wed, 14 Jan 2004 13:06:03 -0800 (PST) (envelope-from cristjc@comcast.net) X-Authentication-Warning: blossom.cjclark.org: cjc set sender to cristjc@comcast.net using -f Date: Wed, 14 Jan 2004 13:06:03 -0800 From: "Crist J. Clark" To: Isaac Gelado Message-ID: <20040114210603.GA49090@blossom.cjclark.org> References: <52975.148.243.211.1.1074063556.squirrel@mail.unixmexico.com> <4004F329.1000902@tid.es> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4004F329.1000902@tid.es> User-Agent: Mutt/1.4.1i X-URL: http://people.freebsd.org/~cjc/ cc: freebsd-isp@freebsd.org cc: freebsd-hackers@freebsd.org cc: nbari@unixmexico.com Subject: Re: Routing Networks X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: "Crist J. Clark" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jan 2004 21:06:21 -0000 On Wed, Jan 14, 2004 at 08:43:37AM +0100, Isaac Gelado wrote: > Nicol?s de Bari Embr?z G. R. escribi?: > >Hi all, I need some help routing or making Nat on a LAN. > > > >I have something like this: > > > > > > I N T E R N E T > > ----------------- > > ^ ^ > > | | > >fxp0 public IP public IP > > | | > > FreeBSD server LINUX server > > | | > >dc0 192.168.10.1 | > >dc1 192.168.1.1 ^ 192.168.1.3 > > ^ | ^ > > | | | > > | | | > > ---------------- > > | Switch/Hub | > > ---------------- > > | | > > ------------------ ----------------- > > | LAN A | | LAN B | > > | 192.168.10.2-254 | | 192.168.1.4-100 | > > ------------------ ----------------- > > > > > >What i want to do is that a computer on LAN A with an IP on the range of > >192.168.10.2-254 can ping, telnet, ssh, etc. to a computer on LAN B > >"192.168.1.X". > > > >How can i solve this problem, is this is a route or Nat problem ? > > I think it is a route problem. You must add next static route: > > - On the linux machine route all incoming packets with dest addr > 192.168.10.x to 192.168.1.1 > > It shouldn't be necesary a static route on the freebsd machine since it > has a network device with an addr of LAN B. This is correct. Things can get from LAN A to LAN B just fine in this picture. The problem is that machines on LAN B won't be able to get back to LAN A (i.e. your pings go from A to B, but the pongs never get back from B to A). You'll have to touch that Linux box or touch the routes on everything on LAN B to route 192.168.10.0/24 through 192.168.1.1. > Of course you must run a > route daemon in both machines (I supouse it's running now since they are > working as gateways) and the previous route must be added to the route > daemon running on the linux machine. OK now here is the problem. Why does he need a routing daemon? I saw no mention of RIP, OSPF, or any other dynamic routing protocol. Looks like it's all static routes to me. -- Crist J. Clark | cjclark@alum.mit.edu | cjclark@jhu.edu http://people.freebsd.org/~cjc/ | cjc@freebsd.org