1. Set Environment Variables
Baidu network disk download https://pan.baidu.com/s/1tbOJiOG9l87HbIzsLApX4A extraction code t657 (mysql-5.7.25 size after decompression 1.6G 300M)
navicat 12 for mysql Activator https://pan.baidu.com/s/1eYJocOkPd7PMhE--tZX7nQ extraction code 4ter
MYSQL_HOME extraction path C: \ DevelopTool \ MySQL \ mysql -5.7.25-winx64
Path %MYSQL_HOME%\bin
2. Create a file my.ini
[client]
port = 3306
default-character-set = utf8mb4
[mysql]
default-character-set = utf8mb4
[mysqld]
basedir = D:\Mysql\mysql-5.7.25-winx64
datadir = D:\Mysql\mysql-5.7.25-winx64\data
port = 3306
character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
init_connect = 'SET NAMES utf8mb4'
sql_mode = NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
Explain
basedir = D: \ Mysql \ mysql -5.7.25-winx64 ( your extraction path)
DATADIR = D: \ Mysql \ MySQL-5.7.25-Winx64 \ Data (your extraction path \ Data)
3. The administrator runs powershell
In the console input mysqld -install successfully is ok
Continue to enter the command mysqld --initialize --user = mysql --console will generate a temporary password to get a few small books down root @ localhost: behind the password is
Continue mysqld install MySQL --defaults-file = " C: \ DevelopTool \ MySQL \ mysql-5.7.25-winx64 \ my.ini" your path \ my.ini
You can now start net start mysql
Change password mysql -u root -p into mysql temporary password and then set the input your password SET PASSWORD = PASSWORD ( '123' );
Can test the exit to exit, MySQL -u root -p enter
Today to worship! Do not forget that the point of a like oh ha ha ha.