mysql8.0.30的RPM包安装方法

来源:这里教程网 时间:2026-03-01 16:50:17 作者:

                                   mysql8.0.30的RPM包安装方法

1、RPM包的安装顺序如下:

rpm -ivh mysql-community-client-plugins-8.0.30-1.el7.x86_64.rpm rpm -ivh mysql-community-common-8.0.30-1.el7.x86_64.rpm yum remove mysql-libs rpm -ivh mysql-community-libs-8.0.30-1.el7.x86_64.rpm rpm -ivh mysql-community-client-8.0.30-1.el7.x86_64.rpm yum install openssl-libs rpm -ivh mysql-community-icu-data-files-8.0.30-1.el7.x86_64.rpm rpm -ivh mysql-community-server-8.0.30-1.el7.x86_64.rpm

2、启动

systemctl start mysqld

3、查看初始密码

 more /var/log/mysqld.log 2022-09-22T03:52:03.704142Z 0 [System] [MY-013169] [Server] /usr/sbin/mysqld (mysqld 8.0.30) initializing of server in progress as process 447912022-09-22T03:52:03.713380Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.2022-09-22T03:52:04.736016Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.2022-09-22T03:52:05.733605Z 6 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: .O/axplLr9ei2022-09-22T03:52:07.978819Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.30) starting as process 448382022-09-22T03:52:07.997204Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.2022-09-22T03:52:08.612731Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.2022-09-22T03:52:09.088371Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.2022-09-22T03:52:09.088421Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.2022-09-22T03:52:09.122718Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.0.30'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  MySQL Community Server - GPL.2022-09-22T03:52:09.123749Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock

4、登录并修改初始密码

 mysql -uroot -p'.O/axplLr9ei'mysql: [Warning] Using a password on the command line interface can be insecure.Welcome to the MySQL monitor.  Commands end with ; or \g.Your MySQL connection id is 8Server version: 8.0.30mysql> alter user root@localhost identified by 'xy_WQ123#';Query OK, 0 rows affected (0.01 sec)

相关推荐