1.修改Mysql配置文件 /etc/mysql/my.cnf
註釋掉 bind-address = 127.0.0.1
2.重啟Mysql /etc/init.d/mysql restart
3.root登錄用戶賦予許可權
mysql -uroot -ppassword
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'yxserver' WITH GRANT OPTION;
FLUSH PRIVILEGES;
4. 在/etc/hosts.allow
增加如下行:
mysqld: ALL