时间:2021-07-01 10:21:17 帮助过:52人阅读
以root身份登入mysql
mysql -u root -p
创建可外网登陆用户
CREATE USER 'custom'@'%.example.com' IDENTIFIED BY 'user_password';
为用户授权
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP ON customer.* TO 'custom'@'%';
检查/etc/mysql/my.cnf,去掉绑定ip
重启服务
sudo service mysql restart