From owner-freebsd-questions Fri Jan 31 19:57: 5 2003 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 7266B37B401 for ; Fri, 31 Jan 2003 19:57:03 -0800 (PST) Received: from oak1a.cats.ohiou.edu (oak.cats.ohiou.edu [132.235.8.44]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9D14E43F75 for ; Fri, 31 Jan 2003 19:57:02 -0800 (PST) (envelope-from tq101100@oak.cats.ohiou.edu) Received: from oak2a.cats.ohiou.edu (oak2a.cats.ohiou.edu [132.235.8.47]) by oak2a.cats.ohiou.edu (8.12.5/8.12.5) with ESMTP id h113u9Wg1405612 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NOT); Fri, 31 Jan 2003 22:56:09 -0500 (EST) Date: Fri, 31 Jan 2003 22:56:09 -0500 (EST) From: Thaddeus Jerome Quintin X-X-Sender: tq101100@oak2a.cats.ohiou.edu To: Mike Meyer Cc: freebsd-questions@FreeBSD.ORG Subject: Re: A twisted home network In-Reply-To: <15931.6311.627786.913544@guru.mired.org> Message-ID: References: <3E3B05AD.90805@attbi.com> <188996853.1044039149@[192.168.0.2]> <15931.6311.627786.913544@guru.mired.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-MailScanner-VirusCheck: Found to be clean X-MailScanner-SpamCheck: X-MailScanner-Information: http://www.cns.ohiou.edu/email/spam-virus.html Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Thanks Mike! (and everyone else who replied!) It's ALMOST working.... I've got my other machines coming up with network access, but they don't seem to resolve DNS. I tried assigning DNS servers manually (the same ones that I use for my FreeBSD machine) (that led them to time out) and i've tried leaving them blank(instant failure). Is there something else that I need to set up? Thanks guys- Thaddeus On Fri, 31 Jan 2003, Mike Meyer wrote: > In <188996853.1044039149@[192.168.0.2]>, Thaddeus Quintin typed: > > There's plenty of information on how to install two network cards (done > > that), how to enable a FreeBSD box to run as a gateway, do NAT, DHCP, etc. > > However, I'm having a mental block with how the cards should be configured. > > > > Here's how I want my network setup- > > CABLE MODEM-> D-link DI-701 Residential Gateway-> > > FreeBSD NIC dc0 -> FreeBSD NIC ep1 -> hub -> other computers... > > > > Where I get confused is how configure my network cards. Do I need a new IP > > prefix for the inner network? > > That's one way to solve it. You need two subnets. > > > If the FreeBSD is a gateway, technically each NIC is connected to a > > different subnet, right? > > Right. In fact, FreeBSD gets upset if they aren't connected to > different subnets. > > > The card that will connect to the hub will need a Static IP address, > > since nothing is there to give an IP address. > > Right. > > > Does each NIC know of the other, or are the routing tables separate? > > NICs don't have routing tables. The system has a routing table, and > knows about both nics. > > > This seems like a simple problem, but I've been scouring the handbook, > > freebsd diary, and the man pages, but I can't find any good examples. > > Call the dc0 side of the FreeBSD box subnet 0. Call the ep0 side > subnet 1 . Let's use the same prefix (192.168) for all the subnets, > and set up for 256 subnets of 256 hosts. > > The dlink is 192.168.0.1, so it's already right for subnet 0. Give the > dc0 the IP address of 192.168.0.2. Or let dchp assign it to any value > on 192.168.0.2. > > Ep1 is on subnet 1, so lets make it host 1, and give it the address of > 192.168.1.1. The other hosts on subnet 1 must have addresses on > 192.168.1. Their default router will be 192.168.1.1. > > The netmask for dc0, ep1 and all hosts on subnet 1 is > 255.255.255.0. > > The dlink will need to know that the route to 192.168.1 is via > 192.168.0.2. Without knowing details on it, I can't say how to set > things up to give it that information. > > I also note that my dlink - a cable/DSL router - only understands > 192.168.0 addresses. If that's the case, you'll have to subnet > 192.168.0, not 192.168. as I just demonstrated. That would look like > dc0 being 192.168.0.2, ep1 being 192.168.0.129, other on subnet 1 > having last bytes greater than 130, and everybody having a netmask of > 255.255.255.128. > > -- > Mike Meyer http://www.mired.org/consulting.html > Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information. > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message