mysql 解压版 安装步骤详情,本人亲测

1.下载地址:https://cdn.mysql.com//Downloads/MySQL-5.7/mysql-5.7.26-winx64.zip

2.在解压目录中添加 data文件夹 和 my.ini文件 

结构如下:如果没data 请不要手动去创建!请手动创建my.ini

mysql 解压版 安装步骤详情,本人亲测

3.在my.ini中配置

[client]
port=3306
default-character-set=utf8
[mysqld]
# 设置mysql的安装目录
basedir=D:/mysql/mysql-5.7.26-winx64
# 设置mysql的数据目录
datadir=D:/mysql/mysql-5.7.26-winx64/data
character_set_server=utf8
sql_mode=NO_ENGINE_SUBSTITUTION,NO_AUTO_CREATE_USER
# 创建新表时将使用的默认存储引擎
default-storage-engine=INNODB
# 开启查询缓存
explicit_defaults_for_timestamp=true
skip-grant-tables

4.配置环境变量

新建MYSQL_HOME变量,并配置值为: D:\mysql\mysql-5.7.26-winx64
编辑path系统变量,将%MYSQL_HOME%\bin添加到path变量后。配置path环境变量,也可不新建MYSQL_HOME变量,而是直接将MySQL安装目录下的bin配置到path变量下,Path:%MYSQL_HOME%\bin

5.以管理员身份打开dos命令行窗口(必须管理员),执行

D:\mysql\mysql-5.7.26-winx64\bin>mysqld -install
Service successfully installed.

这一步一定要记好你的初始密码!

D:\mysql\mysql-5.7.26-winx64\bin>mysqld --initialize --user=root --console

2017-12-20T08:13:45.264865Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-12-20T08:13:45.854579Z 0 [Warning] InnoDB: New log files created, LSN=45790
2017-12-20T08:13:45.998772Z 0 [Warning] InnoDB: Creating foreign key constraint system tables.
2017-12-20T08:13:46.098118Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 9755c3ea-a6f1-11e5-81a3-74d02b122fb3.
2017-12-20T08:13:46.121617Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2017-12-20T08:13:46.135153Z 1 [Note] A temporary password is generated for root@localhost: g!gRw!d%M0Sj

初始化了以后,可以看到MySQL目录下,多了data目录5)D:\mysql\mysql-5.7.26-winx64\bin>net start mysql

D:\Service\mysql57\bin>mysql -u root -p

Enter password: ************
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 4
Server version: 5.7.26

Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

然后改密码! 

格式:mysql> set password for 用户名@localhost = password(‘新密码'); 

例子:mysql> set password for root@localhost = password(‘123');

原创:https://www.panoramacn.com
源码网提供WordPress源码,帝国CMS源码discuz源码,微信小程序,小说源码,杰奇源码,thinkphp源码,ecshop模板源码,微擎模板源码,dede源码,织梦源码等。

专业搭建小说网站,小说程序,杰奇系列,微信小说系列,app系列小说

mysql 解压版 安装步骤详情,本人亲测

免责声明,若由于商用引起版权纠纷,一切责任均由使用者承担。

您必须遵守我们的协议,如果您下载了该资源行为将被视为对《免责声明》全部内容的认可-> 联系客服 投诉资源
www.panoramacn.com资源全部来自互联网收集,仅供用于学习和交流,请勿用于商业用途。如有侵权、不妥之处,请联系站长并出示版权证明以便删除。 敬请谅解! 侵权删帖/违法举报/投稿等事物联系邮箱:2640602276@qq.com
未经允许不得转载:书荒源码源码网每日更新网站源码模板! » mysql 解压版 安装步骤详情,本人亲测
关注我们小说电影免费看
关注我们,获取更多的全网素材资源,有趣有料!
120000+人已关注
分享到:
赞(0) 打赏

评论抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

您的打赏就是我分享的动力!

支付宝扫一扫打赏

微信扫一扫打赏