美文网首页
centos7 mysql8大小写不敏感

centos7 mysql8大小写不敏感

作者: Swye | 来源:发表于2020-05-24 16:01 被阅读0次

1.停止数据库服务后,修改vi /etc/my.cnf,在[mysqld]下面添加 lower_case_table_names=1

2.做好备份,删除数据库数据

rm -rf /var/lib/mysql

3.重启数据库  service mysql start

4.查找密码 grep 'temporary password' /var/log/mysqld.log

5.修改密码,密码8位以上,大小写符号数据

ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '****';update user set host = "%" where user='root';

FLUSH PRIVILEGES;

相关文章

网友评论

      本文标题:centos7 mysql8大小写不敏感

      本文链接:https://www.haomeiwen.com/subject/pxrjahtx.html