Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 20 Sep 2000 00:30:45 -0500 (CDT)
From:      BWS - Offwhite <brennan@offwhite.net>
To:        Chip <chip@wiegand.org>
Cc:        cjclark@alum.mit.edu, "seafug@dub.net" <seafug@dub.net>, "freebsd-questions@freebsd.org" <freebsd-questions@FreeBSD.ORG>
Subject:   Re: natd does port forwarding?
Message-ID:  <Pine.BSF.4.21.0009200027500.84504-100000@home.offwhite.net>
In-Reply-To: <39C84A4B.766B5B24@wiegand.org>

next in thread | previous in thread | raw e-mail | index | archive | help
I just helped a co-worker set up FreeBSD with ipfw/natd on his home
computer.  He is a recent Linux convert and he had a couple
problems.  Here is how we solved them.

It appears your config is much like his and I made sure he had the
firewall set to open while testing and gateway_enable is rc.conf was set
to YES.  That did not help, so I figured he did not turn on the proper
support in the kernel.  You want things like IPDIVERT turned on.  Also
turn on all the good firewall stuff.

If that does not work, I can work with you to make this work for you.  I
have done this quite a bit lately.  I have some good config files which
are pretty good now.

Brennan Stehling - web developer and sys admin
projects: www.greasydaemon.com | www.onmilwaukee.com | www.sncalumni.com

On Tue, 19 Sep 2000, Chip wrote:

> According to top natd is running, in fact, after a reboot it
> showed two instances of it running. I have attached my rc.conf,
> rc.firewall, and natd.conf in the hopes that someone can tell
> me where I have gone wrong, because port forwarding is not
> working.
> More details in the text below for any new readers.
> The firewall is basically the default, I will tighten up the
> rules 
> after I get port-forwarding running.
> Any help would be greatly appreciated.
> -- 
> Chip W.	
> www.wiegand.org
> Alternative Operating Systems
> "Crist J . Clark" wrote:
> > 
> > On Mon, Sep 18, 2000 at 11:09:12PM -0700, Chip wrote:
> > > "Crist J . Clark" wrote:
> > > >
> > > > On Mon, Sep 18, 2000 at 10:42:36PM -0700, Chip wrote:
> > > > > I am wanting to redirect requests to my web site on a public
> > > > > isp to my newly set up apache web server at home (using this -
> > > > > <meta http-equiv="Refresh" Content="5;
> > > > > url=http://208.194.173.26">; which does work fine).
> > > > > I have natd enabled and natd interface specified in the rc.conf,
> > > > > and divert sockets compiled into the kernel. It appears that natd
> > > > > will
> > > > > redirect incoming http requests to my web server with my
> > > > > natd.conf written like this-
> > > > >
> > > > > use_sockets yes
> > > > > same_ports yes
> > > > > interface ep1
> > > > > redirect_port tcp 192.168.0.7 80 80
> > > > >
> > > > > Or so it should, I guess. In the services file I have
> > > > > natd    8668/divert
> > > > > but I have seen it written up as
> > > > > natd    6668/divert
> > > > > in some sources, which is correct?
> > > > >
> > > > > Also, when I enter natd at the command line I get the
> > > > > following message -
> > > > > natd: aliasing address not given
> > > >
> > > > How are you starting natd(8)? With,
> > > >
> > > >   # natd -f /etc/natd.conf
> > > >
> > > > Right?
> > >
> > > It starts at boot, but that command does work. Though I found my
> > > natd in /usr/local/sbin/ and natd.conf in /etc.
> > 
> > What version of FreeBSd are you running? natd should be /sbin/natd for
> > 4.x. IIRC, it is (or was) /usr/sbin/natd in 3.x. /etc/natd.conf is
> > wherever you put it. It does not exist by default.
> > 
> > > Now there is a
> > > copy of both in both directories, which is probably not right,
> > > but it is running and does start on boot-up.
> > 
> > Both directories?
> > --
> > Crist J. Clark                           cjclark@alum.mit.edu



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0009200027500.84504-100000>