#查询当前所有用户
select user,host from mysql.user;
#添加用户
flush privileges;
CREATE USER '用户名'@'%' IDENTIFIED BY '密码';
#给权限
grant select,insert,update,delete on *.* to 用户名@'%' Identified by '密码';
#运行远程访问
GRANT ALL ON *.* TO 用户名@'%' IDENTIFIED BY '密码' WITH GRANT OPTION;