Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 18 Jul 2003 00:10:15 -0400
From:      Paul Chvostek <paul+fbsd@it.ca>
To:        "Frans-Jan v. Steenbeek" <FST777@phreaker.net>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: building a routing machine
Message-ID:  <20030718041015.GA15680@mail.it.ca>
In-Reply-To: <1058500610.260.8.camel@FST777>
References:  <1058500610.260.8.camel@FST777>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jul 18, 2003 at 03:56:53AM +0000, Frans-Jan v. Steenbeek wrote:
> 
> my webserver has two LAN-cards, my desktop has one. My question is: how
> do I connect these two with eachother so that both PC's can reach
> internet?
> 
> I've enabled routed on both systems, (-s on the webserver, -q on the
> desktop) but that doesn't seem to be enough. I've read something about
> routing and gateways in the handbook, but I didn't quite get it. So can
> anyone help me out?

You'd only use routing if each PC had a public IP address, and one
address was routed (upstream from your pair of machines) to the other.
If you have only one IP address, that address needs to be on the server
with two NICs, and you need to set up a *private* network for the
communication between your two machines.  You'll sort of turn your web
server into a firewall, rather than a router.

To connect to the Internet in general from your desktop, you'll probably
want to run natd.  The man page for natd should be your starting point.

-- 
  Paul Chvostek                                             <paul@it.ca>
  it.canada                                            http://www.it.ca/
  Free PHP web hosting!                            http://www.it.ca/web/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030718041015.GA15680>