1. Problem Forgot password for mysql5.7 under linux 2. Solution • Step 1: Open the mysql5.7 configuration file my.cnf and add a line to it: skip-grant-tables Save and exit (:wq) • Step 2: Restart mysql •Step 3: Log in to mysql and change the password Log in with the root account: Use the mysql database in mysql: mysql> use mysql; Change password: Refresh the database: Exit: quit; Note: The password field in the user table of MySQL 5.7 has been changed to the authentication_string field. At this time, the command you need to enter is update user set authentication_string = password("Szfore_68638") where user="root"; • Step 4: Open the mysql5.7 configuration file my.cnf, delete the line you just added: skip-grant-tables, save and exit (:wq) Summarize The above is what I introduced to you about how to solve the problem of forgetting the password of Mysql5.7 under Linux. 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! You may also be interested in:
|
<<: Basic implementation method of cross-component binding using v-model in Vue
>>: mysql database to retrieve the statements of seconds, minutes, hours and days before and after
Frequently asked questions When you are new to ea...
question The seamless scrolling of pictures and t...
This section starts with the details of text modi...
question First, let me talk about the problem I e...
For a newly created website, take ASP.NET MVC5 as...
Table of contents 1. What is an Operating System ...
Pure front-end implementation:切片上傳斷點續傳.斷點續傳needs ...
undefined In JavaScript, if we want to determine ...
Although the frequency of starting the shell is v...
After installing docker, there will usually be a ...
Preface When you install MySQL, you usually creat...
MySql Download 1. Open the official website and f...
There are two most commonly used methods to insert...
Portainer Introduction Portainer is a graphical m...
Installing Electron cnpm install electron -g Inst...