1. Download my Baidu network disk address:
Link: https://pan.baidu.com/s/1HBuXAfSCXNd75BZSrW9Nlg
Extraction code: lhtf
2. Decompression: red frame, build by yourself
4. The name of the initialization configuration file my.ini is arbitrary, the suffix cannot be arbitrary, and the path is adjusted according to your actual path
[mysqld]
port = 3306
basedir=D:/Java/mysql-8.0.20/mysql-8.0.20-winx64
datadir=D:/Java/mysql-8.0.20/mysql-8.0.20-winx64/data
max_connections=200
character-set-server=utf8
default-storage-engine=INNODB
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
[mysql]
default-character-set=utf8
5. MySQL environment configuration:
6. Switch to the bin directory and execute: mysqld --initialize to generate root account and random password
7. Install the mysqld service: mysqld --install
8. Start MySQL: net start mysql
9. Login user: mysql -u root -p (use the random password in step 6 for the password)
10. Modify the root password: