远程连接MySQL 10038

Ubuntu安装mysql后,Navicat for MySQL连接时,出现 Can't connect to mysql server on xxx.xxx.xxx.xxx(10038) 的问题。

解决方案:

1、授权

root@user:/#  mysql -uroot -pyourpassword

mysql>grant all privileges on *.*  to  'root'@'%'  identified by 'yourpassword'  with grant option;

mysql>flush privileges;

2、修改/etc/mysql/my.conf

找到bind-address = 127.0.0.1这一行

改为bind-address = 0.0.0.0即可

posted on 2016-06-16 14:28  宁静vs致远  阅读(459)  评论(0编辑  收藏  举报

导航