序言:
MySQL是世界上最受欢迎的数据库管理系统之一。无论是在小型开发项目上还是在大型网站上面,它都是稳定的、可靠、快速、可信的,可以足够胜任任何数据存储需求。
PS:嘿嘿,其实本人学习MySQL主要原因是想要学习SQL注入,但是在学习的过程中也遇见了一些问题,把问题及问题的解决方案分享出来希望能够帮助到那些遇到相同问题的人,若有不足,请各位大佬多多斧正。
参考资料:
Mysql - flush privileges 命令:
https://blog.youkuaiyun.com/zhangzheng0413/article/details/7243265
操作系统:Microsoft Windows 10 21H1
MySQL版本:MySQL Community Server 8.0.26
Java环境:
Java™ SE Runtime Environment (build 15.0.1+9-18)
Java HotSpot™ 64-Bit Server VM (build 15.0.1+9-18, mixed mode, sharing)
安装过程:
Java环境搭建:
看一看龙龙之前写过的吧,不过多赘述了呦~~(主要是比较懒,嘿嘿):
https://blog.youkuaiyun.com/weixin_46056304/article/details/108987409?spm=1001.2014.3001.5502
网址:
https://dev.mysql.com/downloads/mysql/
一、安装:
C:\Windows\system32>d: #切换到D盘
D:>cd MySQL\SQL\bin #切换到MySQL文件夹
D:\MySQL\SQL\bin>mysqld --initialize --console #初始化MySQL
2021-07-26T11:51:37.672431Z 0 [System] [MY-013169] [Server] D:\MySQL\SQL\bin\mysqld.exe (mysqld 8.0.26) initializing of server in progress as process 6024
2021-07-26T11:51:37.679627Z 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.
2021-07-26T11:51:37.695772Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2021-07-26T11:51:38.187110Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2021-07-26T11:51:39.493894Z 0 [Warning] [MY-013746] [Server] A deprecated TLS version TLSv1 is enabled for channel mysql_main
2021-07-26T11:51:39.494483Z 0 [Warning] [MY-013746] [Server] A deprec
《一线大厂Java面试题解析+后端开发学习笔记+最新架构讲解视频+实战项目源码讲义》
【docs.qq.com/doc/DSmxTbFJ1cmN1R2dB】 完整内容开源分享
ated TLS version TLSv1.1 is enabled for channel mysql_main
2021-07-26T11:51:39.594086Z 6 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: havj1rP#5Xct #初始密码
D:\MySQL\SQL\bin>mysqld install #安装MySQL
The service already exists!
The current server installed: D:\MySQL\SQL\bin\mysqld MySQL
D:\MySQL\SQL\bin>net start mysql #启动服务
MySQL 服务正在启动 .
MySQL 服务已经启动成功。
D:\MySQL\SQL\bin>mysql -u root -p #登录
Enter password: ************
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 8.0.26
Copyright © 2000, 2021, Oracle and/or its affiliates.
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>
二.修改密码:
C:\Users\ASUS\Desktop>mysql -u root -p #使用初始密码登录
Enter password: *********
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 16
Server version: 8.0.26 MySQL Community Server - GPL
Copyright © 2000, 2021, Oracle and/or its affiliates.
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> use mysql;