玩转MySQL优化命令

1、MySQL更改为只能本地登录
# use mysql;
# select user,host,Password from user where user='root';
# delete from user where user='root' and host='%';
2、MySQL授予外网登陆权限

grant all privileges on *.* to 授予外网登陆的用户名@'%' identified by '密码' WITH GRANT OPTION;

# grant all privileges on *.* to root@'%' identified by 'root' WITH GRANT OPTION;
# flush privileges;
3、更改MySQL的存储目录
    原文作者:試毅_思伟
    原文地址: https://segmentfault.com/a/1190000019813084
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞