Vocany
Vocany

Reputation: 29

Adding a remote DB in MySQL Workbench

I am able to connect to a remote MySQL database that is hosted on a Ubuntu VM through SSH and can add the database in MySQL Workbench at my home desktop. However, when I am travelling and using my laptop, I can still connect using SSH, however I cannot use the database in MySQL Workbench. I am having trouble figuring out a solution for this problem. Any help is appreciated.

Upvotes: 0

Views: 565

Answers (2)

Vocany
Vocany

Reputation: 29

The reason I was unable to add the database through MySQL Workbench was simply because I forgot to open the port for the connection. Simple user error.

Upvotes: 0

stackoverflow
stackoverflow

Reputation: 78

If you can't connect the DataBase using your Workbench, the workbench will give you an error. What is the error code? Is there any decription or information? MySQL's default server port is 3306, the connect user must have the privileges to connect the server from another PC.

Use use mysql; select Host,User from user; Confirm that the Host's value is '%', not 'localhost' or something else. Then check port 3306 is open on your server. Type netstat -an | grep 3306 or netstat -tln on your SSH console. Make sure you can find 3306 LISTEN Then check your workbench configuation, make sure these are all correct.

Without the error code and decription, that is all the reasons and solutions I can give you. Wish this would help you.

Upvotes: 1

Related Questions