By the default installation, MySQL does not allow remote access to the server. When you tried to directly connect to the server, you will find the following error:
Failed to connect to MySQL at <mysql server ip address>:3306 with user root
Found and tried solutions on how to enables the MySQL connection, but the result is not good. System would returns an error of
ERROR 2002 (HY000) can't connect to local MySQL server through socket '/var/run/mysqld/mysql.sock' (2)
Solution
As the enablement of remote access may caused potential issue, I go back to MySQL workbench to find any hint for the solution.
At this moment, I found that the remote connection to MySQL server could be achieved by Connection Method "Standard TCP/IP over SSH".
After inputting the corresponding information and click "Test connection", successful result returns and can connect to the remote MySQL server.



沒有留言:
張貼留言