当前位置:网站首页>How to handle root password forgetting in MySQL

How to handle root password forgetting in MySQL

2022-06-22 07:56:00 yolo2016

Mysql in root How to handle password forgetting

#/etc/my.conf Add such as down line 
skip-grant-tables 
#######################
systemctl restart mysqld
mysql -uroot
update mysql.user set authentication_string=password('root') where user='root';
flush privileges;

select Host ,User,Password, authentication_string from user;
#/etc/my.conf Add such as down line 
# The notes are as follows skip-grant-tables And restart mysqld After the service, you can log in normally 
原网站

版权声明
本文为[yolo2016]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202220531362216.html