7.运营mysql服务,假如未有运维的话.net start mysql

5.在D:\Program Files\mysql-伍.七.18-winx64索引下新建data文件夹,必须为空。

9.修改root密码

mysql> set password=password('123456');

1.下载mysql社区版

八.在cmd中,使用命令mysql -u root -p,回车进入mysql>命令提醒符。

3.在D:\Program Files\mysql-5.7.18-winx64\bin下,新建文件my.ini,内容如下:

 [client]
 port=3306
 default-character-set=utf8

 [mysqld]
 bind-address = 127.0.0.1
 port=3306
 character_set_server=utf8
 basedir  ="D:\Program Files\mysql-5.7.18-winx64"
 datadir  ="D:\Program Files\mysql-5.7.18-winx64\data"
 tmpdir   ="D:\Program Files\mysql-5.7.18-winx64\data"
 socket   ="D:\Program Files\mysql-5.7.18-winx64\data\mysql.sock"
 log-error="D:\Program Files\mysql-5.7.18-winx64\data\mysql_error.log"

 max_connections=100
 table_open_cache=256
 query_cache_size=1M
 tmp_table_size=32M
 thread_cache_size=8

 innodb_data_home_dir="D:\Program Files\mysql-5.7.18-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"

6.打开cmd,cd到D:\Program Files\mysql-5.7.18-winx64\bin,推行如下命令

mysqld --initialize-insecure
mysqld -install

4.配置C:\WINDOWS\4503.com,system32\drivers\etc\hosts,暗中认可是注释掉的,去掉注释:

127.0.0.1       localhost

2.解压到D:\Program Files