1. Configure environment variables: Right-click "My Computer"-"advanced"-"Environment variables"
3) in the (System variable) path variable (existing without new) Add Variable value: G:\MySQL\mysql-5.7.12-winx64\bin (note the value of the variable with ";" (depending on your installation path)
2, "Start" and "Run"-input "MySQL"--"enter" If no MySQL is not internal or external command, the configuration is successful
3. Run cmd in the bin directory (depending on your installation path)
4. Execute mysqld.exe-install instruction, the service successfully installed prove successful
5. Execute MySQL--initialize command
6. Execute net start mysql command
7. Change Password:
(1) Execution instruction: Mysql-u root-p
(2) Enter the initial password (according to the picture): Enter the data directory, open the. err suffix file, the red circle part is the password, copy and paste
(3) Execution instruction: Alter user ' root ' @ ' localhost ' identified by ' MySQL ';
(4) Execute instruction, change password to root:update mysql.user set Authentication_string=password (' root '), password_expired= ' N ' where user= ' Root ';
(5) Execution instruction: Flush privileges;
8. After configuration, in cmd input: mysql-uroot-proot can enter MySQL
Window configuration MySQL Detailed steps