> 数据库 > MySQL >

MySQL授权远程主机访问

grant all privileges on *.* to 'root'@'192.168.0.81' with grant option;  
 
或下面这条
 
GRANT ALL PRIVILEGES ON *.* TO "root"@"192.168.0.81" IDENTIFIED BY "password";  
 
flush privileges;
 
use mysql;
 
select host,user from user; //查看下用户
(责任编辑:IT)