I am sure that this question has been asked over and over again throughout the internet, but I still need some advice on this issue, as I am not very familiar with all these networking thingy.

I am setting up a server using Apache running under Debian, and also a FTP service using ProFTPD under the same platform. Assuming that the internal IP of my server is, and is a static IP. As for the external IP, it is a dynamic IP, so I have set up a DDNS domain with all those updater working, and say www.example.com maps to my home IP.

So, what I want is, when I enter www.example.com in my web browser, it will show up the web page hosted in my server, can access my FTP using ftp://www.example.com.

My questions are:

1) Am I doing right to forward port 80 and 21 to If not, what are the correct things to do?

2) If I am right, I get the following message after forwarding port 80 (I get the similar message when forwarding port 21):

Since port 80 is used, the DSL Modem Router WEB server port for your remote access will be moved to 8080.

When I enter www.example.com into my web browser, it leads me to my router set up page. When I enter www.example.com:8080, the browser complains that it could not connect to the server.

So I changed my server Apache setting to listen to port 8080, and forward port 8080. Again, when I try to access www.example.com:8080 from my home network, it complains that it could not connect to the server. However, when I access www.example.com:8080 from my friend's house, it shows the content of the web page in my server.

Anyway, my target is to achieve that www.example.com (port 80, not with :8080) shows the web page that is hosted in my server, and ftp://www.example.com let me access my files.

If it helps, the modem router I am using is TP-Link TD-W8960N (If you are trying to search TP-Link site, it is not the latest model. There is a newer model with the same name). The DDNS service that I am using is no-ip.com.


  • Looks like the TD-W8960N_V1_V3_110620 firmware provides NAT loopback. That is what you need to try to access www.example.com:8080 from your home network. – HTTP500 Sep 18 '12 at 16:39

Answer 1: Yes. It is the correct thing to do.

Answer 2: You should disable services running on your router's 80 and 21 ports. Not to forget to enable other methods to access your router for example SSH. Or you can move the router's webserver to another port for example 8080. Or if the router is configurable to make it only listen on the internal side and forward the outer to your machine. So... it is a wery likely thing that none of this your router supports... then you can't easily do what you want.

Addition to answer 2: You can't access your webpage from the internal network because your traffic goes to the outside world through your router because it thinks that your outer IP is in the Internet. You can manage the right working with dirty configurations on your router but you should better to add example.com with the IP to your hosts file. So your computer will look for example.com on itself.

  • I mean I used the other computer to try to access my server. is localhost, no? – yihangho Sep 19 '12 at 9:36
  • Yes, then you have to add your server's IP address on it to the hosts file. – Stone Sep 20 '12 at 20:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.