After mysql is installed, the connection error is reported

Problem: After the mql client is installed, it has been unable to connect, and the manual startup shows that it cannot be started

net start mysql

solution:

1. Check the log

mysqld --console

2. It is possible that there is no data folder under the mysql folder. This folder generally needs to be created by yourself or use the following command

mysqld  --initialize

3. Restart the mysql service

 

After mqsql starts successfully, the connection still fails. You need to check whether the password is correct.

find your initial password

搜索:[Note] A temporary password is generated for root@localhost:

Change password by command

ALTER USER 'root'@'localhost' IDENTIFIED BY '123456';

Note: front-end development, not familiar with the back-end, own solution

 

Reference: https://blog.csdn.net/qq_37915248/article/details/82631398

Guess you like

Origin blog.csdn.net/qq_23334071/article/details/104736380