Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I wish to enable remote access to my linux home server, so I can use it when I'm not home.

I tried doing so using port forwarding as follows:
http://<RouterInternetIP>:<SomePort> =>

but when I try accessing it remotely, I get RSTs (Unable to connect).

What is the best way to configure such rule?

Just to make myself clear. I don't care about security at the moment - I'll deal with it later. Neither do I care about a static DNS address with which I would be able to access my host dynamically - I'm keeping this to a later stage as well.

All I wish to do, at the moment, is to VIEW my home server's apache page, as I can see it from my desktop - just from the internet (assuming I already know its current IP address). I want to be able to write, where is my current address and 10000 is forwarded to 80, and watch the apache page, which is already accessed from within my LAN using http://server:80.

share|improve this question

migrated from Sep 22 '12 at 0:51

This question came from our site for professional and enthusiast programmers.

1. It depends on your router, they all provide a different UI to configure this stuff. 2. Drop the "http://" in that rule there. Forwarding ports takes effect at the TCP layer, not application layer. 3. This is not a programming question and is off topic for SO. – Celada Sep 21 '12 at 22:06
up vote 0 down vote accepted

You will need to be able to open at least one port in your firewall. Provided you can do this, you have several options. If you just need to view your desktop, running VNC is a good option. If you need to access particular services on an occasional basis, SSH tunneling may be your best friend. If you want to connect your remote computer to your entire home network, OpenVPN might be worth your trouble, but it's a good deal more complex to set up properly than the first two options. And like neo1987 mentioned, you're probably going to want to run some kind of dynamic DNS client so you can always reach your computer at a known address. If you don't control your firewalls, you'll need a third part service to act as a go between, and Hamachi might be a good option.

share|improve this answer
I'm not sure I made myself clear enough, so I edited my question. Anyway, I don't talk about my desktop in either case - we can discuss about it as an option to build a home HTTP server and make it accessible across the web (disregarding a static/dynamic address at the point). – Rely Sep 22 '12 at 13:11
I'm assuming that the only firewall you have between your server and your browser is on your router. If this is the case, your task is really simple. You just need to go to your router's administration screen and change it's firewall settings. Almost any router will let you forward port 10000 on the WAN side to server-ip:80 on the LAN side. It works best if your router also allows you to assign the server a permanent LAN IP The specific directions will depend on brand. You might also have to change the firewall rules on your server to open port 80 in your ipchains rules, but probably not. – acjay Sep 22 '12 at 16:55
There goes the weird part: I already forwarded port 10000 to server:80, and assigned a static address to my server. Moreover, I even tried to state that port 80 will be forwarded to port 80 in server, and the router noted me that in this case, it will listen from now on to port 8080 for its web service. I agreed. In neither case, however, the action succeeded - When I try accessing my router (either via, my dynamic IP, or even from an outside network using the dynamic IP) - I still receive RST in case of port 10000, or the web service UI in case of port 80. – Rely Sep 22 '12 at 21:58
I'm not understanding, what do you mean that it will listen from now on to port 8080? Have you checked the firewall rules on your server? Could be your server machine itself is not letting outside packets in on port 80. Can you access your webserver from your LAN? Can you access your webserver from the computer itself (via localhost)? – acjay Sep 23 '12 at 14:31
I can see it easily from the LAN side, using server:80. It's a linux ubuntu server edition. I installed apache 2 using apt-get. Do you have a clue if I should configure something in order to allow remote connections? (By the way, I should say that I even turned DMZ on, and it did not help.) – Rely Sep 24 '12 at 19:47

You can use Dynamic DNS to access your home server via internet. You can find more details here.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .