CentOS7下安装mysql8.0
程序员文章站
2022-03-12 22:04:48
一、下载MySQL Yum Repository如下图所示:选择Red Hat Enterprise Linux 7 / Oracle Linux 7(Architecture Independent),RPM Package。下载地址:MySQL Community Downloads二、安装Yum Repository运行如下代码:sudo rpm -ivh /home/kobe26366/下载/mysql80-community-release-el7-3.noarch.rpm运行...
一、下载MySQL Yum Repository
如下图所示:
选择Red Hat Enterprise Linux 7 / Oracle Linux 7(Architecture Independent),RPM Package。
下载地址:MySQL Community Downloads
二、安装Yum Repository
运行如下代码:
sudo rpm -ivh /home/kobe26366/下载/mysql80-community-release-el7-3.noarch.rpm
运行结果如下:
警告:/home/kobe26366/下载/mysql80-community-release-el7-3.noarch.rpm: 头V3 DSA/SHA1 Signature, 密钥 ID 5072e1f5: NOKEY
准备中... ################################# [100%]
软件包 mysql80-community-release-el7-3.noarch 已经安装
三、使用Yum Repository来安装MySQL 8.0
(1)切换工作目录到 /etc/yum.repos.d
cd /etc/yum.repos.d
(2)执行安装命令
yum install mysql-community-server
安装过程中所有需要选择的都选 y,运行结果如下:
已加载插件:fastestmirror, langpacks Loading mirror speeds from cached hostfile * base: mirrors.aliyun.com * epel: ftp.yz.yamagata-u.ac.jp * extras: mirrors.aliyun.com * updates: mirrors.aliyun.com 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 | 62 kB 00:00:00 (2/3): mysql80-community/x86_64/primary_db | 115 kB 00:00:00 (3/3): mysql-tools-community/x86_64/primary_db | 76 kB 00:00:00 正在解决依赖关系 --> 正在检查事务 ---> 软件包 mysql-community-server.x86_64.0.8.0.21-1.el7 将被 安装 --> 正在处理依赖关系 mysql-community-common(x86-64) = 8.0.21-1.el7,它被软件包 mysql-community-server-8.0.21-1.el7.x86_64 需要 --> 正在处理依赖关系 mysql-community-client(x86-64) >= 8.0.11,它被软件包 mysql-community-server-8.0.21-1.el7.x86_64 需要 --> 正在检查事务 ---> 软件包 mysql-community-client.x86_64.0.8.0.21-1.el7 将被 安装 --> 正在处理依赖关系 mysql-community-libs(x86-64) >= 8.0.11,它被软件包 mysql-community-client-8.0.21-1.el7.x86_64 需要 ---> 软件包 mysql-community-common.x86_64.0.8.0.21-1.el7 将被 安装 --> 正在检查事务 ---> 软件包 mariadb-libs.x86_64.1.5.5.65-1.el7 将被 取代 --> 正在处理依赖关系 libmysqlclient.so.18()(64bit),它被软件包 2:postfix-2.10.1-9.el7.x86_64 需要 --> 正在处理依赖关系 libmysqlclient.so.18(libmysqlclient_18)(64bit),它被软件包 2:postfix-2.10.1-9.el7.x86_64 需要 ---> 软件包 mysql-community-libs.x86_64.0.8.0.21-1.el7 将被 舍弃 --> 正在检查事务 ---> 软件包 mysql-community-libs-compat.x86_64.0.8.0.21-1.el7 将被 舍弃 --> 解决依赖关系完成 依赖关系解决 ========================================================================================================= Package 架构 版本 源 大小 ========================================================================================================= 正在安装: mysql-community-libs x86_64 8.0.21-1.el7 mysql80-community 4.5 M 替换 mariadb-libs.x86_64 1:5.5.65-1.el7 mysql-community-libs-compat x86_64 8.0.21-1.el7 mysql80-community 1.2 M 替换 mariadb-libs.x86_64 1:5.5.65-1.el7 mysql-community-server x86_64 8.0.21-1.el7 mysql80-community 499 M 为依赖而安装: mysql-community-client x86_64 8.0.21-1.el7 mysql80-community 48 M mysql-community-common x86_64 8.0.21-1.el7 mysql80-community 617 k 事务概要 ========================================================================================================= 安装 3 软件包 (+2 依赖软件包) 总下载量:553 M Is this ok [y/d/N]: y Downloading packages: 警告:/var/cache/yum/x86_64/7/mysql80-community/packages/mysql-community-common-8.0.21-1.el7.x86_64.rpm: 头V3 DSA/SHA1 Signature, 密钥 ID 5072e1f5: NOKEY mysql-community-common-8.0.21-1.el7.x86_64.rpm 的公钥尚未安装 (1/5): mysql-community-common-8.0.21-1.el7.x86_64.rpm | 617 kB 00:00:01 (2/5): mysql-community-libs-8.0.21-1.el7.x86_64.rpm | 4.5 MB 00:00:01 (3/5): mysql-community-libs-compat-8.0.21-1.el7.x86_64.rpm | 1.2 MB 00:00:00 (4/5): mysql-community-client-8.0.21-1.el7.x86_64.rpm | 48 MB 00:00:06 (5/5): mysql-community-server-8.0.21-1.el7.x86_64.rpm | 499 MB 00:01:11 ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 总计 7.4 MB/s | 553 MB 00:01:15 从 file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql 检索密钥 导入 GPG key 0x5072E1F5: 用户ID : "MySQL Release Engineering <mysql-build@oss.oracle.com>" 指纹 : a4a9 4068 76fc bd3c 4567 70c8 8c71 8d3b 5072 e1f5 软件包 : mysql80-community-release-el7-3.noarch (installed) 来自 : /etc/pki/rpm-gpg/RPM-GPG-KEY-mysql 是否继续?[y/N]:y Running transaction check Running transaction test Transaction test succeeded Running transaction 警告:RPM 数据库已被非 yum 程序修改。 正在安装 : mysql-community-common-8.0.21-1.el7.x86_64 1/6 正在安装 : mysql-community-libs-8.0.21-1.el7.x86_64 2/6 /sbin/ldconfig: /usr/local/cuda-10.2/targets/x86_64-linux/lib/libcudnn.so.7 不是符号连接 正在安装 : mysql-community-client-8.0.21-1.el7.x86_64 3/6 正在安装 : mysql-community-server-8.0.21-1.el7.x86_64 4/6 正在安装 : mysql-community-libs-compat-8.0.21-1.el7.x86_64 5/6 /sbin/ldconfig: /usr/local/cuda-10.2/targets/x86_64-linux/lib/libcudnn.so.7 不是符号连接 正在删除 : 1:mariadb-libs-5.5.65-1.el7.x86_64 6/6 /sbin/ldconfig: /usr/local/cuda-10.2/targets/x86_64-linux/lib/libcudnn.so.7 不是符号连接 验证中 : mysql-community-server-8.0.21-1.el7.x86_64 1/6 验证中 : mysql-community-libs-8.0.21-1.el7.x86_64 2/6 验证中 : mysql-community-client-8.0.21-1.el7.x86_64 3/6 验证中 : mysql-community-libs-compat-8.0.21-1.el7.x86_64 4/6 验证中 : mysql-community-common-8.0.21-1.el7.x86_64 5/6 验证中 : 1:mariadb-libs-5.5.65-1.el7.x86_64 6/6 已安装: mysql-community-libs.x86_64 0:8.0.21-1.el7 mysql-community-libs-compat.x86_64 0:8.0.21-1.el7 mysql-community-server.x86_64 0:8.0.21-1.el7 作为依赖被安装: mysql-community-client.x86_64 0:8.0.21-1.el7 mysql-community-common.x86_64 0:8.0.21-1.el7 替代: mariadb-libs.x86_64 1:5.5.65-1.el7 完毕!
本文地址:https://blog.csdn.net/qq_41072222/article/details/107398466
上一篇: mysql的表分区