1. Uninstall the previously installed MySQL service
Check the registry hkey_local_machine\system\controlset001\services\mysql, some words delete the item, then return to cmd inside output mysqld--remove Enter, the service Successfully removed. Represents the deletion success.
2. Go to the folder directory and locate the My-default.ini file, and copy the name to My.ini.
3. Modify the Configuration
[Mysqld]
#basedir代表自己MySQL的安装根目录
Basedir = d:\\mysoftware\\mysql-5.7.9-winx64
#datadir代表自己MySQL的数据库保存的目录, if you do not create a new data folder in the root directory of the MySQL installation
DataDir = D:\\mysoftware\\mysql-5.7.9-winx64\\data
#port代表端口号
Port = 3306
Sql_mode=no_engine_substitution,strict_trans_tables
4. In the DOS window, switch directories to the root of MySQL and execute bin\mysqld--defaults-file=my.ini--initialize-insecure
5. Perform the bin\mysqld--install and install the MySQL service, and the service successfully installed will be displayed successfully.
6. Finally start the MySQL service, execute the net start MySQL in the Command line window
MySQL free install version service starts