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

I'm trying to tunnel into a remote server for the purposes of debugging(so I could get a more specific error message rather than internal server error 500), and I was looking at the question: phpmyadmin forbidden through ssh tunnel

I tunnel in successfully using the command ssh -L 8080:localhost:80 www.remotesite.com

But, when I try to connect using my browser using the URL www.remotesite.com:8080/ext/test/registration.php I'm unable to connect. What am I doing wrong?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

The command ssh -L 8080:localhost:80 www.remotesite.com connects to the server at www.remotesite.com and asks to tunnel localhost:80 (which would be www.remotesite.com itself) to the 8080 port of the client initiating the ssh connection.

In other words: you need to connect to localhost (your own workstation, not the server) on port 8080, that is where the entrance of your tunnel lies.

The URI then becomes: http://localhost:8080/ext/test/registration.php

share|improve this answer
Ah, thank you. I was a bit confused. –  Garzahd Feb 16 '13 at 0:11

Your Answer


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.