Remote Mysql Server SSH Login

Remote Server Login and Port Tunneling

You can log into your Remote Server by through SSH (Secure Shell Login) or PuTTy. PuTTy is for Windows machine to log into your Remote Server. Linux machine users no need to have PuTTy. Linux users can log into the Remote Server through Command Line SSH

The MySql ports on Web server only opened to local ports by default for security reasons. To access Mysql database on webserver from a client tool like the MySQL Query Browser, normally youíd have to open up access from your local IP address. Use port-forwarding through an SSH tunnel, so your MySQL client thinks itís connecting to your localhost machine, but itís really connecting to the other server through the tunnel

To create the Mysql tunnel Use the following Command
ssh -L 3306:localhost:3306 user@example.com

You could also use this technique to port-forward through one ssh server to another server

If you already have mysql running on your local machine then you can use a different local port for the port-forwarding, and just set your client tools to access MySQL on a different port

Open up the Mysql query browser and enter in the details for your remote server, using localhost as the server host, and adjust the port to whatever you used


Related Topic SSH Secured Shell Configurations and Security Best Practices
What are all the Important Elements of SSH
Change MySQL Root Password
How to Restart mysql in linux
How to Change or Set New Root Password for Mysql Database
SQL  mysql  ssh  web server  

nScraps.com © 2011   Privacy Policy  Terms of Service  Feedback