From owner-freebsd-questions Fri Mar 14 15:40:47 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 7605F37B401 for ; Fri, 14 Mar 2003 15:40:44 -0800 (PST) Received: from mta01-svc.ntlworld.com (mta01-svc.ntlworld.com [62.253.162.41]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6322343F75 for ; Fri, 14 Mar 2003 15:40:43 -0800 (PST) (envelope-from matt@overdose.com) Received: from overdose.com ([80.0.158.31]) by mta01-svc.ntlworld.com (InterMail vM.4.01.03.37 201-229-121-137-20020806) with ESMTP id <20030314234042.HTMQ6166.mta01-svc.ntlworld.com@overdose.com>; Fri, 14 Mar 2003 23:40:42 +0000 Date: Fri, 14 Mar 2003 23:42:14 +0000 Subject: Re: Port Forwarding FreeBSD 4.7_Release Content-Type: text/plain; charset=US-ASCII; format=flowed Mime-Version: 1.0 (Apple Message framework v551) Cc: dan@slightlystrange.org, freebsd-questions@FreeBSD.ORG To: Bill Moran From: Matthew Ryan In-Reply-To: <3E71DD46.2070207@potentialtech.com> Message-Id: <95C9542C-5676-11D7-8E90-0030654886A6@overdose.com> Content-Transfer-Encoding: 7bit X-Mailer: Apple Mail (2.551) 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 Bill and Dan, Thanks for your help guys it's sort of working now but for the record here's the story. All attempts to start port forwarding from the command line were failing because NATD was already running (enabled at boot time) DOH! > b) natd isn't already running with different options when you try to > start it on the command line? Well spotted Bill! The /etc/rc.conf entry: natd_flags="-redirect_port tcp 192.168.1.241:xxxx xxxx" was fine since: natd_interface="ep0" specified the interface. All in all I just should have posted the whole of my /etc/rc.conf in the first place. Sorry about that. The real irony is that it was working all along!! I just didn't know because i was trying to access the service on the external IP address of my router from an internal IP address. When I tried to access it via. my other connection (in effect from outside) everything worked fine. I'm sure that there is some reasonable explanation for this to do with the way that NAT operates but I can't figure it out. Any clues? Thanks Again Matthew Ryan Matt@overdose.com > Daniel Bye wrote: >> On Fri, Mar 14, 2003 at 01:07:42PM +0000, Matthew Ryan wrote: >>> Thanks Dan >>> >>> Unfortunately that doesn't seem to work either. >> Rats! >>> I get this when I enter on the command line: >>> >>> natd -n ep0 -redirect_port tcp 192.168.1.241:xxxx xxxx >>> >>> natd: Unable to create divert socket.: Operation not permitted >> Silly question, I'm almost blushing to ask - you are running the >> command as >> root, yes? > > Also ... are you sure that: > a) You have your kernel configured with IPDIVERT? The GENERIC kernel > does _not_. > b) natd isn't already running with different options when you try to > start it on the command line? > >>> and no results using the following in /etc/rc.conf: >>> >>> natd_flags="-n ep0 -redirect_port tcp 192.168.1.241:xxxx xxxx" >>> >>> By the way, the interface is specified already in /etc/rc.conf as >>> follows?: >>> >>> natd_interface="ep0" > > This is redundant. You can remove the "-n ep0" from natd_flags. > >>> any other ideas? > > I don't know _whats_ wrong. > But I've got this running in two places with no problems. It > works just fine, and as far as I can see, the syntax you're using is > correct, so I wouldn't focus on that. Let us know what you find when > you check the suggestions I made ... I have other suggestions if > those don't help. > > -- > Bill Moran > Potential Technologies > http://www.potentialtech.com > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > > Matthew Ryan Matt@overdose.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message