Pretty simple stuff, say you are using mysql administrator and you want to point it at a server that you have ssh access to but the firewall prevents you from making a direct connection over the internet (which it should).

Here is what you do (if mysql is running on its default port):

ssh -N -L3306:localhost:3306 username@server.com

You can also pass in a port variable if you are running ssh on a non-starndard port (which you should also do) all you do is add ” -p 1234” (1234 would be the port number where ssh is wanting you to connect)

Now just point mysql administrator at 127.0.0.1 and supply your credentials. Bang. You’re in.

1 Response to “Open an ssh Tunnel to Administer MySQL (or anything else)”

  1. Julie Says:

    Hi Steven,

    How do I get in touch with you? I have multiple Flex/Flash positions open!!

    Julie Hansen

Leave a Reply