use mysql;
grant all privileges on *.* to USERNAME@'IP/HOSTNAME' identified by 'PASSWORD' with grant option;
flush privileges;
最好从允许访问的远程服务器连接测试一下
use mysql;
grant all privileges on *.* to USERNAME@'IP/HOSTNAME' identified by 'PASSWORD' with grant option;
flush privileges;
最好从允许访问的远程服务器连接测试一下