From owner-freebsd-questions Thu Jan 28 07:02:53 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id HAA27106 for freebsd-questions-outgoing; Thu, 28 Jan 1999 07:02:53 -0800 (PST) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from smtp1.vnet.net (smtp1.vnet.net [166.82.1.31]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id HAA27092 for ; Thu, 28 Jan 1999 07:02:48 -0800 (PST) (envelope-from rivers@dignus.com) Received: from dignus.com (ponds.vnet.net [166.82.177.48]) by smtp1.vnet.net (8.9.1a/8.9.1) with ESMTP id KAA05042; Thu, 28 Jan 1999 10:03:23 -0500 (EST) Received: from lakes.dignus.com (lakes.dignus.com [10.0.0.3]) by dignus.com (8.9.1/8.8.5) with ESMTP id KAA04287; Thu, 28 Jan 1999 10:46:39 -0500 (EST) Received: (from rivers@localhost) by lakes.dignus.com (8.9.1/8.6.9) id KAA13328; Thu, 28 Jan 1999 10:06:08 -0500 (EST) Date: Thu, 28 Jan 1999 10:06:08 -0500 (EST) From: Thomas David Rivers Message-Id: <199901281506.KAA13328@lakes.dignus.com> To: Jeff.Bond@nectech.co.uk, questions@FreeBSD.ORG Subject: Re: Setting up a FreeBSD box as a gateway to my ISP In-Reply-To: <084DD226F592D211988800A024AC583B2692DB@exchange.nectech.co.uk> Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG > > Hello, > > I would like to know how I can setup an old 486 running 2.2.7 to act as a > 'gateway' to my ISP, so that other PCs (running Win98 or FreeBSD) on my LAN > can access the internet. > > I can get the 2.2.7 machine to dial and connect to my ISP (Freeserve BTW), > with no problem using pppd, but how do I get it to route data from the other > machines on my LAN to the ISP via my modem? Also, what do I need to setup on > the other machines? (Do I just need to set the 'Gateway' box in win98 to the > ethernet IP of my FreeBSD machine?) The LAN is just a simple ethernet, using > IP's such as 10.0.0.X. The FreeBSD machine with the modem is 10.0.0.1. I get > a dynamic IP address for the ppp0 interface each time I dial my ISP. > > I'm not so bothered with dial-on-demand and such like at the moment, just > the actual routing of the packets. > > What's the easiest way to do this? > 1) Turn the GATEWAY option on in /etc/rc.conf 2) If you have a set of IP addresses for the internal machines, you're all done. If not - you'll need to use Network Address Translation (NAT) to make the machines on your interior network "appear the same as" the single machine you have connected to the external network. To set up nat; you need to get IPFW (the firewall stuff) going, which will mean a kernel build. Then, after that's done, you can set up natd - the network translation deamon. Or - I believe a much simpler approach, since you're using ppp is to investigate the -alias option on ppp. - Dave Rivers - To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message