centos7安装mysql 8.0_CentOS7.8安装mysql 8.0.20的教程详解

一、安装mysql软件

下载并安装MySQL官方的 Yum Repository,Mysql版本8.0.20

wget -i -c

http://dev.mysql.com/get/mysql80-community-release-el7-3.noarch.rpm

下载后直接yum安装

yum -y install mysql80-community-release-el7-3.noarch.rpm

安装MySQL服务器

yum -y install mysql-community-server

[root@CentOS Linux]# yum -y install mysql-community-server

Loaded plugins: fastestmirror, langpacks

Loading mirror speeds from cached hostfile

* base: mirror.lzu.edu.cn

* extras: mirror.lzu.edu.cn

* updates: mirror.lzu.edu.cn

mysql-connectors-community | 2.5 kB 00:00:00

mysql-tools-community | 2.5 kB 00:00:00

mysql80-community | 2.5 kB 00:00:00

(1/3): mysql-connectors-community/x86_64/primary_db | 57 kB 00:00:00

mysql-tools-community/x86_64/p FAILED B 00:51:07 ETA

http://repo.mysql.com/yum/mysql-tools-community/el/7/x86_64/repodata/12bd1e8730cd532791529877bf5e7babbbb02879-primary.sqlite.bz2: [Errno 12] Timeout on http://repo.mysql.com/yum/mysql-tools-community/el/7/x86_64/repodata/12bd1e8730cd532791529877bf5e7babbbb02879-primary.sqlite.bz2: (28, 'Operation too slow. Less than 1000 bytes/sec transferred the last 30 seconds')

Trying other mirror.

(2/3): mysql-tools-community/x86_64/primary_db | 72 kB 00:00:00

mysql80-community/x86_64/prima FAILED B 00:00:15 ETA

http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/repodata/833c637b3989c2dd5a079a045177d2f1c96e9c1e-primary.sqlite.bz2: [Errno 12] Timeout on http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/repodata/833c637b3989c2dd5a079a045177d2f1c96e9c1e-primary.sqlite.bz2: (28, 'Operation too slow. Less than 1000 bytes/sec transferred the last 30 seconds')

Trying other mirror.

(3/3): mysql80-community/x86_64/primary_db | 107 kB 00:00:00

Resolving Dependencies

--> Running transaction check

---> Package mysql-community-server.x86_64 0:8.0.20-1.el7 will be installed

--> Processing Dependency: mysql-community-common(x86-64) = 8.0.20-1.el7 for package: mysql-community-server-8.0.20-1.el7.x86_64

--> Processing Dependency: mysql-community-client(x86-64) >= 8.0.11 for package: mysql-community-server-8.0.20-1.el7.x86_64

--> Running transaction check

---> Package mysql-community-client.x86_64 0:8.0.20-1.el7 will be installed

--> Processing Dependency: mysql-community-libs(x86-64) >= 8.0.11 for package: mysql-community-client-8.0.20-1.el7.x86_64

---> Package mysql-community-common.x86_64 0:8.0.20-1.el7 will be installed

--> Running transaction check

---> Package mariadb-libs.x86_64 1:5.5.65-1.el7 will be obsoleted

--> Processing Dependency: libmysqlclient.so.18()(64bit) for package: 2:postfix-2.10.1-9.el7.x86_64

--> Processing Dependency: libmysqlclient.so.18(libmysqlclient_18)(64bit) for package: 2:postfix-2.10.1-9.el7.x86_64

---> Package mysql-community-libs.x86_64 0:8.0.20-1.el7 will be obsoleting

--> Running transaction check

---> Package mysql-community-libs-compat.x86_64 0:8.0.20-1.el7 will be obsoleting

--> Finished Dependency Resolution

Dependencies Resolved

===============================================================================================

Package Arch Version Repository Size

===============================================================================================

Installing:

mysql-community-libs x86_64 8.0.20-1.el7 mysql80-community 4.5 M

replacing mariadb-libs.x86_64 1:5.5.65-1.el7

mysql-community-libs-compat x86_64 8.0.20-1.el7 mysql80-community 1.2 M

replacing mariadb-libs.x86_64 1:5.5.65-1.el7

mysql-community-server x86_64 8.0.20-1.el7 mysql80-community 488 M

Installing for dependencies:

mysql-community-client x86_64 8.0.20-1.el7 mysql80-community 47 M

mysql-community-common x86_64 8.0.20-1.el7 mysql80-community 609 k

Transaction Summary

===============================================================================================

Install 3 Packages (+2 Dependent packages)

Total download size: 541 M

Is this ok [y/d/N]: y

Downloading packages:

warning: /var/cache/yum/x86_64/7/mysql80-community/packages/mysql-community-common-8.0.20-1.el7.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY

Public key for mysql-community-common-8.0.20-1.el7.x86_64.rpm is not installed

(1/5): mysql-community-common-8.0.20-1.el7.x86_64.rpm | 609 kB 00:00:00

(2/5): mysql-community-libs-8.0.20-1.el7.x86_64.rpm | 4.5 MB 00:00:13

(3/5): mysql-community-libs-compat-8.0.20-1.el7.x86_64.rpm | 1.2 MB 00:00:04

mysql-community-client-8.0.20- FAILED B 00:22:23 ETA

http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-8.0.20-1.el7.x86_64.rpm: [Errno 12] Timeout on http://repo.mysql.com/yum/mysql-8.0-community/el/7/x86_64/mysql-community-client-8.0.20-1.el7.x86_64.rpm: (28, 'Operation too slow. Less than 1000 bytes/sec transferred the last 30 seconds')

Trying other mirror.

(4/5): mysql-community-server-8.0.20-1.el7.x86_64.rpm | 488 MB 00:22:18

(5/5): mysql-community-client-8.0.20-1.el7.x86_64.rpm | 47 MB 00:01:57

-----------------------------------------------------------------------------------------------

Total 376 kB/s | 541 MB 00:24:34

Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql

Importing GPG key 0x5072E1F5:

Userid : "MySQL Release Engineering "

Fingerprint: a4a9 4068 76fc bd3c 4567 70c8 8c71 8d3b 5072 e1f5

Package : mysql80-community-release-el7-3.noarch (installed)

From : /etc/pki/rpm-gpg/RPM-GPG-KEY-mysql

Is this ok [y/N]: y

Running transaction check

Running transaction test

Transaction test succeeded

Running transaction

Warning: RPMDB altered outside of yum.

Installing : mysql-community-common-8.0.20-1.el7.x86_64 1/6

Installing : mysql-community-libs-8.0.20-1.el7.x86_64 2/6

Installing : mysql-community-client-8.0.20-1.el7.x86_64 3/6

Installing : mysql-community-server-8.0.20-1.el7.x86_64 4/6

Installing : mysql-community-libs-compat-8.0.20-1.el7.x86_64 5/6

Erasing : 1:mariadb-libs-5.5.65-1.el7.x86_64 6/6

Verifying : mysql-community-libs-compat-8.0.20-1.el7.x86_64 1/6

Verifying : mysql-community-common-8.0.20-1.el7.x86_64 2/6

Verifying : mysql-community-server-8.0.20-1.el7.x86_64 3/6

Verifying : mysql-community-client-8.0.20-1.el7.x86_64 4/6

Verifying : mysql-community-libs-8.0.20-1.el7.x86_64 5/6

Verifying : 1:mariadb-libs-5.5.65-1.el7.x86_64 6/6

Installed:

mysql-community-libs.x86_64 0:8.0.20-1.el7

mysql-community-libs-compat.x86_64 0:8.0.20-1.el7

mysql-community-server.x86_64 0:8.0.20-1.el7

Dependency Installed:

mysql-community-client.x86_64 0:8.0.20-1.el7 mysql-community-common.x86_64 0:8.0.20-1.el7

Replaced:

mariadb-libs.x86_64 1:5.5.65-1.el7

Complete!

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值