The Great God wrote:
https://www.cnblogs.com/ericli-ericli/p/6916285.html
cattle, afraid of what the page is deleted, just copy it, are the source, the god Wuguai
step 1
Download the official website: https://dev.mysql.com/downloads/mysql/
Select manual installation version:
Mysql to extract the D drive folder:
Than the previous version is missing two .ini files directly copy over, modify, my.ini:
Press Ctrl + C to copy the code
[client]
port=3306
default-character-set=utf8
[mysqld]
# 设置为MYSQL的安装目录
basedir=D:\\mysql\\mysql-5.7.18-winx64
# 设置为MYSQL的数据目录
datadir=D:\\mysql\\mysql-5.7.18-winx64\data
port=3306
character_set_server=utf8
sql_mode=NO_ENGINE_SUBSTITUTION,NO_AUTO_CREATE_USER
#开启查询缓存
explicit_defaults_for_timestamp=true
skip-grant-tables
Press Ctrl + C Copy the code
(my-default.xml and it may be the same)
Step Two
Set the environment variable:
put your mysql bin directory to which the configuration environment variable
Step Three
Execute as administrator cmd,
Input:
1, into the program storage bin directory
2, mysqld --initialize-insecure
sentence command is to make the data have normal mysql directory folder and related files
look data directory, the file appears below what we need:
then:
mysqld install
There is a problem, there may appear, service has exist, it is the service already exists.
You can first delete the service, and then install the service, as follows
sc delete mysql
mysqld install
The message is to be the administrator mode can be successful.
Here is start the service:
First, the need to increase the final my.ini in the root directory of the file mysql sentence: skip-grant-tables, otherwise fail (you can also add the outset)
net start mysql
change the password:
set password for root@localhost = password('123456');
mysql -u root -p
Author: Eric Li
Source: http://www.cnblogs.com/ericli-ericli/
except reprinted articles, essays and blog garden belongs to the author of all, welcome to reprint, please indicate the source.
If you feel this post you gain something, think of pretty carefully, please click on the bottom right of the [recommended], thank you!
Reproduced in: https: //www.jianshu.com/p/8e9c924d7cef