First, start MySQL in skip-grant-tables mode: From now on, you will step into the first pit, if you use the wrong modification method posted everywhere on the Internet: mysql> UPDATE mysql.user SET authentication_string=PASSWORD('your_new_password') WHERE User='root'; (Note that after 5.7, password is changed to authentication_string) Congratulations, you have successfully modified it, but you will find that when you use a GUI tool such as navicat to connect, the following error will be reported: ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement. At the same time, you will find that the command line can use The following command will save you: mysql> SET PASSWORD = PASSWORD('your_new_password'); After execution, shut down mysqld using the command Start mysql again with mysql.server start and everything will be ok~ The above is the method I introduced to you to change the root password of Mysql5.7.10 version under MAC. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website! You may also be interested in:
|
<<: Detailed explanation of vite+ts to quickly build vue3 projects and introduce related features
>>: Detailed explanation of mktemp, a basic Linux command
1. Install basic components First, execute the yu...
React originated as an internal project at Facebo...
Sometimes, we need to copy a whole column of data...
Table of contents Preface What is Deno? Compariso...
Unzip the file into a directory This is the direc...
1. Native network request 1. XMLHttpRequest (w3c ...
background Before we know it, a busy year is comi...
Scenario How to correctly render lists up to 1000...
Enable remote access rights for mysql By default,...
The company had a well-configured server that was...
Table of contents 1. Function signature 2. Functi...
The default arrangement of text in HTML is horizo...
1. Introduction to nmon Nmon (Nigel's Monitor...
CSS CodeCopy content to clipboard .bottomTable{ b...
Today, after the game was restarted, I found that...