1: Download 64-bit MySQL compression pack: http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.17-winx64.zip
2: Decompression, the path of self-determined, mine is in the S:\program\mysql-5.7.4-m14-winx64.
3: New My.ini, content as follows, I copy from the online one:
################### #配置文件开始 ################### # for advice in how to change settings * See # Http://dev.mysql.com/doc /refman/5.6/en/server-configuration-defaults.html # * * * does not EDIT the this FILE. It's a template which'll be copied to the # * * * * default location during install, and'll be replaced if you # * * * Upgra De to a newer version of MySQL. [Client] Default-character-set=utf8 [mysqld] port=3306 basedir= "s:/program/mysql-5.7.4-m14-winx64" datadir= "S:/ program/mysql-5.7.4-m14-winx64/data/"tmpdir=" s:/program/mysql-5.7.4-m14-winx64/data/"socket=" S:/program/ Mysql-5.7.4-m14-winx64/data/mysql.sock "log-error=" S:/program/mysql-5.7.4-m14-winx64/data/mysql_error.log "# server_id = 2 #skip-locking max_connections=100 table_open_cache=256 query_cache_size=1m Tmp_table_size=32M thread_ Cache_size=8 innodb_data_home_dir= "s:/program/mysql-5.7.4-m14-winx64/data/" Innodb_flush_log_at_trx_commit =1 innodb_log_buffer_size=128m innodb_buffer_pool_size=128m innodb_log_file_size=10m innodb_thread_concurrency=16 innodb-autoextend-increment=1000 join_buffer_size = 128M sort_buffer_size = 32M read_rnd_buffer_ Size = 32M Max_allowed_packet = 32M explicit_defaults_for_timestamp=true sql-mode= "strict_trans_tables,no_auto_create _user,no_engine_substitution "#sql_mode =no_engine_substitution,strict_trans_tables################### #配置文件结束 # # # ################
Note that there is a path where you want to change the path.
Where the DataDir path must be xxx/data/. (What happens if you don't use this path?) There's no test here ... )
4: In the System environment variable, add the path:
; S:\program\mysql-5.7.4-m14-winx64\bin; (Replace with your own path, note to add a semicolon)
5: Run cmd, run with administrator privileges, and then switch to Bin:
Execute Add service command: mysqld intall MySQL (MySQL is the name of the service, this can be taken casually)
The command to remove the service is: mysqld remove MySQL
6: Then Control Panel-Admin tool-Services, find MySQL, right-click to start.
7: Change root password:
Command line execution: Mysql–uroot
Mysql>show databases;
Mysql>use MySQL;
mysql> UPDATE user SET Password=password (' 123456 ') WHERE user= ' root ';
mysql> FLUSH privileges;
Mysql> QUIT
Now that MySQL is installed, you can then log in with the visualization tool. If you are Telnet, you need to add permissions. Here for the time being, I will not elaborate.
Note: I encountered a 1067 error when I started the service, and after checking I found that the path configuration in My.ini was wrong.