From owner-freebsd-questions@FreeBSD.ORG Sat Sep 10 03:06:37 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 6264316A41F for ; Sat, 10 Sep 2005 03:06:37 +0000 (GMT) (envelope-from ltsampros@upnet.gr) Received: from mail.vivodinet.gr (mail3.vivodinet.gr [80.76.39.13]) by mx1.FreeBSD.org (Postfix) with SMTP id 5CE5143D46 for ; Sat, 10 Sep 2005 03:06:35 +0000 (GMT) (envelope-from ltsampros@upnet.gr) Received: (qmail 68 invoked from network); 10 Sep 2005 03:06:31 -0000 Received: from dslcustomer-222-89.vivodi.gr (HELO bifteki.home.net) (83.171.222.89) by 0 with SMTP; 10 Sep 2005 03:06:31 -0000 Received: from bifteki.home.net (localhost [127.0.0.1]) by bifteki.home.net (8.13.4/8.13.3) with ESMTP id j8A66IGr002234 for ; Sat, 10 Sep 2005 06:06:18 GMT (envelope-from gaghiel@bifteki.home.net) Received: (from gaghiel@localhost) by bifteki.home.net (8.13.4/8.13.3/Submit) id j8A66I2N002233 for freebsd-questions@freebsd.org; Sat, 10 Sep 2005 06:06:18 GMT (envelope-from gaghiel) Date: Sat, 10 Sep 2005 06:06:18 +0000 From: Leonidas Tsampros To: freebsd-questions@freebsd.org Message-ID: <20050910060618.GA2199@bifteki.lan> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i Subject: Re: Strange (newbie) Gateway Errors X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Sep 2005 03:06:37 -0000 On Fri, Sep 09, 2005 at 08:58:41PM -0400, Thomas Dimson wrote: > Hi, > > Sorry if this is out of place, but I am having an issue with forwarding > packets on my freebsd-current box from a windows PC. > > Here what I'm trying to do: > I have two network cards, one on a university network and one going to a > router, which is connected to a cable modem. Both cards use the vr driver. > University is configured through DHCP, private router is just specified ( > 192.168.1.110 ). I am trying to route traffic to the > internet through the router while keeping all university traffic internal. > > Problem: > I run a traceroute from my freebsd box to the university network and it > works fine. I can access the website (129.97.128.40 ) > through the internal network. However, using my windows PC - with the > freebsd server specified as a gateway - it just times out when trying to > connect to the web site. Any website on the internet works fine, but not the > intranet. > > Here is my config, I am just setting a static route to the ip of the website > to test for now: > netstat -r > Routing tables > > Internet: > Destination Gateway Flags Refs Use Netif Expire > default 192.168.1.1 UGS 0 119789 vr0 > localhost localhost UH 0 0 lo0 > 129.97.128.40/32 cn-rtrev-res15net. UGS 0 12 vr1 > 192.168.1 link#1 UC 0 0 vr0 > 192.168.1.1 00:20:78:ce:cb:b4 UHLW 2 154 vr0 1172 > 192.168.1.107 00:11:95:5d:0b:7f UHLW 1 210110 vr0 945 > > Internet6: > Destination Gateway Flags Netif Expire > localhost localhost UH lo0 > fe80::%vr0 link#1 UC vr0 > fe80::20d:88ff:fe7 00:0d:88:7f:42:d0 UHL lo0 > fe80::%vr1 link#2 UC vr1 > fe80::211:95ff:fee 00:11:95:e2:57:40 UHL lo0 > fe80::%lo0 fe80::1%lo0 U lo0 > fe80::1%lo0 link#4 UHL lo0 > ff01:: localhost U lo0 > ff02::%vr0 link#1 UC vr0 > ff02::%vr1 link#2 UC vr1 > ff02::%lo0 localhost UC lo0 > > Can anyone provide me with aid, or at least the location of a log file for > the gateway functions of the machine? Try to add gateway_enable="YES" in /etc/rc.conf and run either # /etc/routing start [as root] or reboot the pc. Actually , when you want your freebsd to act as a gateway , you have to set the sysctl variable net.inet.ip.forwarding to 1. However , the gateway_enable options takes care of this.