Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a pyLoad machine in my local network which connects with autossh to my hosted virtual server so that I can access pyLoad from wherever I am. Now I want to have access to the API port which is connected to the virtual server:

tcp 0 0 127.0.0.1:65153 0.0.0.0:* LISTEN

How can I make this port (which is only available on the localhost of the virtual server) accessible for remote connections? Thanks

share|improve this question

1 Answer 1

Generally, you can't. The 127.0.0.0/8 netblock is reserved and unroutable.

But you can tunnel to it. From a remote machine, you could do

ssh virtualserver -L 12345:localhost:65153

and then, on your remote machine, local port 12345 will be connected through to virtualserver's port 65153.

But there's no way to make any machine's localhost accessible from off-server without using some kind of private network (VPN, ssh tunneling, proxy).

share|improve this answer
    
I solved it with a nginx proxy_pass argument for the webinterface port of pyLoad on port 8000 which is now accessible online on port 80 so I thought it must be possible for another port, too but not with nginx / a webserver!? –  Peleke Jul 2 '13 at 20:37
    
See above: VPN, ssh tunneling, proxy. A decent webserver makes a fine proxy (see many comparable questions on SF). –  MadHatter Jul 3 '13 at 6:49

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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