赞
踩
MySQL 5.7 到 8.0,Oracle 官方跳跃了 Major Version 版本号,随之而来的就是在 MySQL 8.0 上做了许多重大更新,在往企业级数据库的路上大步前行,全新 Data Dictionary 设计,支持 Atomic DDL,全新的版本升级策略,安全和账号管理加强,InnoDB 功能增强等,目前小版本已经 release 到 8.0.23,新的功能仍然在持续推出。MySQL 8.0是全球最受欢迎的开源数据库的一个非常令人兴奋的新版本,全面改进。一些关键的增强包括:
登录官网https://dev.mysql.com/downloads/mysql/下载最新版本的mysql8,需要使用oracle官网账号登录后方可下载,如果没有可以先免费注册一个。
[root@centos8 opt]# ll
total 262080
-rw------- 1 root root 237666304 Mar 6 01:53 mysql-8.0.23-1.el8.x86_64.rpm-bundle.tar
[root@centos8 opt]# tar -xvf mysql-8.0.23-1.el8.x86_64.rpm-bundle.tar
mysql-community-client-8.0.23-1.el8.x86_64.rpm
mysql-community-client-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-client-plugins-8.0.23-1.el8.x86_64.rpm
mysql-community-client-plugins-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-common-8.0.23-1.el8.x86_64.rpm
mysql-community-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-debugsource-8.0.23-1.el8.x86_64.rpm
mysql-community-devel-8.0.23-1.el8.x86_64.rpm
mysql-community-libs-8.0.23-1.el8.x86_64.rpm
mysql-community-libs-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-server-8.0.23-1.el8.x86_64.rpm
mysql-community-server-debug-8.0.23-1.el8.x86_64.rpm
mysql-community-server-debug-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-server-debuginfo-8.0.23-1.el8.x86_64.rpm
mysql-community-test-8.0.23-1.el8.x86_64.rpm
mysql-community-test-debuginfo-8.0.23-1.el8.x86_64.rpm
按照顺序安装
[root@centos8 opt]# rpm -ivh mysql-community-common-8.0.23-1.el8.x86_64.rpm
[root@centos8 opt]# rpm -ivh mysql-community-client-plugins-8.0.23-1.el8.x86_64.rpm
[root@centos8 opt]# rpm -ivh mysql-community-libs-8.0.23-1.el8.x86_64.rpm
[root@centos8 opt]# rpm -ivh mysql-community-client-8.0.23-1.el8.x86_64.rpm
[root@centos8 opt]# rpm -ivh mysql-community-server-8.0.23-1.el8.x86_64.rpm
[root@centos8 opt]# systemctl start mysqld
[root@centos8 opt]# cat /var/log/mysqld.log |grep localhost
2021-03-06T11:34:00.498314Z 6 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: C&%(Kc7Jlb>a
[root@centos8 opt]# mysqladmin -uroot -p password ‘Test!123’
Enter password:
mysqladmin: [Warning] Using a password on the command line interface can be insecure.
Warning: Since password will be sent to server in plain text, use ssl connection to ensure password safety.
mysql> select version();
±----------+
| version() |
±----------+
| 8.0.23 |
±----------+
1 row in set (0.00 sec)
至此mysql8安装完成。
说明:这是关于自动创建的mysql临时文件清理规则配置文件
[root@centos8 tmpfiles.d]# vim +23 /usr/lib/tmpfiles.d/mysql.conf
…
d /var/run/mysqld 0755 mysql mysql -
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。