摘要:
第一步:vim /etc/mysql/my.cnf找到bind-address = 127.0.0.1注释掉这行,如:#bind-address = 127.0.0.1或者改为: bind-address = 0.0.0.0允许任意IP访问;或者自己指定一个IP地址。重启 MySQL:sudo /etc/init.d/mysql restart第二步:授权用户能进行远程连接 grant all privileges on *.* to root@"%" identified by "password" with grant option; flush p 阅读全文