Skip to content

Tag Archives: ssh

How can I tunnel a local MySQL server through SSH?

06-Nov-09

Setting up the Tunnel
The most common methods of setting up a tunnel are through putty or through command-line SSH.
To open an SSH tunnel via the command line, run:
ssh -L3307:127.0.0.1:3306 -p 22 -N -t -x user@myhost.com
Connecting with MySQL
You can connect to the MySQL server!
You want to choose 3307 for your local port so that it does [...]