Re: Newbie- Port Forwarding -- does not work

From: Rudolf Ladyzhenskii (rudolfl_at_optusnet.com.au)
Date: 05/07/04


Date: Sat, 8 May 2004 00:38:53 +1000

Hi, all

To answer my own question -- this setup does actually work.
 What did not work is my test setup.

By some reason, I can only access this website from LAN by using LAN
address. If I try to get to it by using its external address, it does not go
through IPTABLES by the look of it.

A asked my friend to try it and all is fine.

Rudolf

"Rudolf Ladyzhenskii" <rudolfl@optusnet.com.au> wrote in message
news:409b9b75$0$4543$afc38c87@news.optusnet.com.au...
> Hi, all
>
> I was about to post a question about port forwarding when I saw this
thread.
> So I decided to post here.
>
> I have apachee web server running on my Internet router machine. I also
have
> another web server on my local LAN that I want to be seen outside. So, I
> thought the easiest way would be to do port forwarding.
> I deciced to use port 8081 to get access to my internal web server (I made
> it to work on port 8081 and it is OK on LAN).
>
> So, in my iptables configuration I have exactly what was suggested in this
> thread. Here is what I have:
>
> $IPTABLES -A INPUT --protocol tcp --dport 8081 -j ACCEPT #http
forwarding
> $IPTABLES -A FORWARD -j ACCEPT -p tcp --dport 8081
> $IPTABLES -t nat -A PREROUTING -d xxx.xxxx.xxxx.xxxx --protocol
tcp --dport
> 8081 -j DNAT
> --to-destination 192.168.1.48
>
> I can not see any pages on my web server.
>
> Any ideas what I am doing wrong?
>
> Thanks,
> Rudolf
>
>
> "Ivan" <linuxdk@programmer.dk> wrote in message
> news:409b288c$0$203$edfadb0f@dread16.news.tele.dk...
> > iptables -A INPUT -j ACCEPT -p tcp --dport 25
> > iptables -A FORWARD -j ACCEPT -p tcp --dport 25
> > iptables -t nat -A PREROUTING -d xxx.xxx.xxx -p tcp --dport 25 -j
> DNAT --to
> > 192.168.0.123
> >
> > "Prince Of Thieves" <thief_NOSPAM@hotmail.com> skrev i en meddelelse
> > news:gzTVb.4$NS3.267@nnrp1.ozemail.com.au...
> > > Hi,
> > >
> > > I'm a complete Newbie, so tread lightly with me.
> > >
> > > I have a Linux server running:
> > >
> > > Debian GNU/Linux 3.0 webserver
> > > Linux webserver 2.4.23-uv1
> > >
> > > This is our firewall to the corporate network. I assume that it is
port
> > > forwarding port #25 to our Exchange V5.5 server. I wish to change
this,
> so
> > > that it port-forwards to another server which is running an Anti-spam
> > > package.
> > >
> > > How do I do this? Step-by-step instructions are gonna get me real far
on
> > > this issue, thanks!
> > >
> > >
> > > --
> > >
> > > Prince Of Thieves
> > >
> > >
> > >
> > >
> > >
> >
> >
>
>



Relevant Pages

  • bt voyager router configuration question
    ... server running on my LAN and have set up port forwarding so incoming ... External users can access the web server no problem. ... On a PC on my LAN I can access the web server using its local IP ... I get the web page for the router. ...
    (uk.telecom.broadband)
  • Re: Access NATted webserver from inside the network
    ... >>192.168.0.54 is the stable IP of your web server you use port forwarding ... > So i would like to be able to access it like if i was outside the LAN, ... >>BTW, not knowing your netmask, I'm assuming that your web server is truly ...
    (comp.os.linux.networking)
  • Re: port forwarding -- nat/ipfw
    ... I can't get port forwarding to work within or outside the LAN. ... My natd.conf on my router machine looks like this: ... Internet to your external IP and will have no effect on LAN ...
    (comp.unix.bsd.freebsd.misc)
  • RE: How to tell if port 25 for SMTP is enabled
    ... For Port Forwarding the following configuration is required on Dlink G604t ... To configure Port Forwarding for any IP Address on LAN, ... > router. ...
    (microsoft.public.windows.server.sbs)
  • Re: port forwarding -- nat/ipfw
    ... I can't get port forwarding to work within or outside the LAN. ... My natd.conf on my router machine looks like this: ... Internet to your external IP and will have no effect on LAN ...
    (comp.unix.bsd.freebsd.misc)