From owner-freebsd-questions@FreeBSD.ORG Fri Jul 23 00:56:54 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2AE0816A4CE for ; Fri, 23 Jul 2004 00:56:54 +0000 (GMT) Received: from lakermmtao05.cox.net (lakermmtao05.cox.net [68.230.240.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id B218343D1F for ; Fri, 23 Jul 2004 00:56:53 +0000 (GMT) (envelope-from james.coulter@cox.net) Received: from sabrina ([68.105.58.150]) by lakermmtao05.cox.net (InterMail vM.6.01.03.02.01 201-2131-111-104-103-20040709) with ESMTP id <20040723005652.XRIH29398.lakermmtao05.cox.net@sabrina>; Thu, 22 Jul 2004 20:56:52 -0400 From: "James A. Coulter" To: Date: Thu, 22 Jul 2004 19:56:33 -0500 Message-ID: <000401c4704f$e6691470$6e01a8c0@sabrina> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: quoted-printable X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.6626 In-Reply-To: <200407131906.05044.admin@swedehost.com> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 cc: 'Dancho Penev' Subject: SOLVED: NEWBIE: FreeBSD 4.10 Internet gateway/DNS problem X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Jul 2004 00:56:54 -0000 > > On Tue, Jul 13, 2004 at 10:51:21AM -0500, James A. Coulter wrote: > > > > > >I am trying to setup my FreeBSD 4.10 box as an internet gateway for = a > > > small home LAN (2x Win XP and 1x Win 98SE) > > > > > >The LAN operates without any problems when using the Win 98SE box = as a > > >gateway - all computers can access the internet > > > > > >I have two nics installed in the FreeBSD box: > > > > > > dc0 is the LAN interface via 4-port Linksys hub > > > > > > dc1 is the WAN interface via cable modem > > > > > >I have successfully connected to the internet with dc1 > > > > > >I can ping all other machines on my home LAN with dc0 and vice = versa > > > > > >I cannot access the internet from any machine except the FreeBSD > gateway > > > > > >ifconfig looks like this: > > > > > > > > >I'm not sure what to do next. For some reason the Windows cannot > access a > > >name server. From what I understand from the literature I've been > using > > >(FreeBSD Handbook, Lehey's The Complete FreeBSD, and Anderson's > FreeBSD: > > > An Open-Source etc etc) all that should be needed is set > > > gateway_enable=3D"YES" in /etc/rc.conf and I've done that. > > > > > >Google revealed some info on using natd for PPOE, but not sure if = that > > >applies to this problem. > > > > Definitely you must use NAT. Search Handbook for Network Address > > Translation. > > > > >All suggestions/out-right solutions appreciated. > > > > > >TIA, > > > > > >Jim C. > > > > Hello. > You might try something like this in your /etc/rc.conf : > gateway_enable=3D"YES" > ifconfig_dc1=3D"DHCP" > dhcp_program=3D"/sbin/dhclient" > dhcp_flags=3D"-q" > ifconfig_dc0=3D"inet 192.168.1.1 netmask 255.255.255.0" > natd_enable=3D"YES" > natd_interface=3D"dc0" > natd_flags=3D"-dynamic" > And if you like some little protection : > firewall_enable=3D"YES" > firewall_script=3D"/etc/rc.firewall" > firewall_type=3D"OPEN" > firewall_logging=3D"YES" > And it's never wrong to spend some time reading the man pages :-) > Don't forget to put the IP of your Gateway on the Winboxes. > /Hasse Sorry for the very late response and thanks very much for the = suggestions to check out NAT. That was of course the problem. Being a newbie and life-long Windows user, I thought gateway_enable=3D"YES" in rc.conf was = the magic word. But it isn't and I read up on NAT and natd and built a = custom kernel with: options IPFIREWALL options IPDIVERT and made the changes to rc.conf as detailed above and now my FreeBSD box = is passing packets back and forth from all the Windows boxes on my LAN to = the WAN beautifully. Thanks again for your help! Jim C.