mysql 8.0.13 安装配置方法图文教程
程序员文章站
2023-03-24 22:51:13
本文为大家分享了mysql 8.0.13 安装配置教程,供大家参考,具体内容如下
下载
下载
解压
解压之后没有my.ini文件(我的端口设置的3308),...
本文为大家分享了mysql 8.0.13 安装配置教程,供大家参考,具体内容如下
下载
下载
解压
解压之后没有my.ini文件(我的端口设置的3308),截图中是我增加的
[client] port = 3308 default-character-set = utf8 [mysqld] port = 3308 character_set_server = utf8 basedir=d:\mysql\mysql-8.0.13-winx64 datadir=d:\mysql\mysql-8.0.13-winx64\data group_concat_max_len=20000 [winmysqladmin] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe
管理员命令行
在mysql安装目录的 bin 目录下执行命令:
mysqld --initialize --console
得到如下结果
d:\mysql\mysql-8.0.13-winx64\bin>mysqld --initialize --console 2018-10-24t05:32:45.732454z 0 [system] [my-013169] [server] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe (mysqld 8.0.13) initializing of server in progress as process 43080 2018-10-24t05:32:45.870611z 0 [warning] [my-013242] [server] --character-set-server: 'utf8' is currently an alias for the character set utf8mb3, but will be an alias for utf8mb4 in a future release. please consider using utf8mb4 in order to be unambiguous. 2018-10-24t05:33:14.879343z 5 [note] [my-010454] [server] a temporary password is generated for root@localhost: mmqp.yfcy5xy 2018-10-24t05:33:37.812581z 0 [system] [my-013170] [server] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe (mysqld 8.0.13) initializing of server has completed d:\mysql\mysql-8.0.13-winx64\bin>
看到有个警告,查了一下mysql建议使用utf8mb4
修改my.ini文件
[client] port = 3308 default-character-set = utf8mb4 [mysqld] port = 3308 character-set-server = utf8mb4 basedir=d:\mysql\mysql-8.0.13-winx64 datadir=d:\mysql\mysql-8.0.13-winx64\data group_concat_max_len=20000 [winmysqladmin] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe
警告没有了
d:\mysql\mysql-8.0.13-winx64\bin>mysqld --initialize --console 2018-10-24t06:06:51.100372z 0 [system] [my-013169] [server] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe (mysqld 8.0.13) initializing of server in progress as process 47804 2018-10-24t06:07:18.372699z 5 [note] [my-010454] [server] a temporary password is generated for root@localhost: nj>uujkph4/i 2018-10-24t06:07:36.024435z 0 [system] [my-013170] [server] d:\mysql\mysql-8.0.13-winx64\bin\mysqld.exe (mysqld 8.0.13) initializing of server has completed d:\mysql\mysql-8.0.13-winx64\bin>
上面打印了默认密码:nj>uujkph4/i
安装服务
mysqld --install mysql8.0
因为这是电脑上第二个mysql 所以服务名改成了 mysql8.0
启动服务
net start mysql8.0
修改初始密码
登录mysql之后执行
alter user 'root'@'localhost' identified with mysql_native_password by '123456';
精彩专题分享:
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持。
推荐阅读
-
JDK1.9怎么安装配置?Java SE 9(JDK9)详细安装教程+环境变量配置方法
-
Android Studio安装配置方法图文教程
-
CentOS7下mysql 8.0.16 安装配置方法图文教程
-
win10下mysql 8.0.16 winx64安装配置方法图文教程
-
mysql 8.0.16 压缩包安装配置方法图文教程
-
Windows10 mysql 8.0.12 非安装版配置启动方法
-
Windows10下mysql 8.0.16 安装配置方法图文教程
-
mysql 8.0.16 winx64.zip安装配置方法图文教程
-
windows下mysql 8.0.16 安装配置方法图文教程
-
win10下mysql 8.0.16 winx64安装图文最新教程