No package devtoolset-9-gcc available No package devtoolset-9-gcc-c++ available.

root@k8s-129 src]# yum -y install gcc tcl centos-release-scl devtoolset-9-gcc devtoolset-9-gcc-c++
Loaded plugins: fastestmirror
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
Package gcc-4.8.5-44.el7.x86_64 already installed and latest version
Package 1:tcl-8.5.13-8.el7.x86_64 already installed and latest version
Package centos-release-scl-2-3.el7.centos.noarch already installed and latest version
No package devtoolset-9-gcc available.
No package devtoolset-9-gcc-c++ available.
Nothing to do

 已经启用了 SCL 仓库,仍然无法找到 devtoolset-9-gccdevtoolset-9-gcc-c++

 1、手动添加 SCL 仓库文件

cat <<EOL > /etc/yum.repos.d/CentOS-SCLo-scl-rh.repo
[centos-sclo-rh]
name=CentOS-7 - SCLo rh
baseurl=http://mirror.centos.org/centos/7/sclo/x86_64/rh/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[centos-sclo-sclo]
name=CentOS-7 - SCLo sclo
baseurl=http://mirror.centos.org/centos/7/sclo/x86_64/sclo/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
EOL

2、清理 YUM 缓存

yum clean all

[root@k8s-129 ~]# yum -y install devtoolset-9-gcc-c++
已加载插件:fastestmirror
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
正在解决依赖关系
There are unfinished transactions remaining. You might consider running yum-complete-transaction, or "yum-complete-transaction --cleanup-only" and "yum history redo last", first to finish them. If those don't work you'll have to try removing/installing packages by hand (maybe package-cleanup can help).
--> 正在检查事务
---> 软件包 devtoolset-9-gcc-c++.x86_64.0.9.3.1-2.2.el7 将被 安装
--> 正在处理依赖关系 devtoolset-9-gcc = 9.3.1-2.2.el7,它被软件包 devtoolset-9-gcc-c++-9.3.1-2.2.el7.x86_64 需要
--> 正在处理依赖关系 devtoolset-9-libstdc++-devel = 9.3.1-2.2.el7,它被软件包 devtoolset-9-gcc-c++-9.3.1-2.2.el7.x86_64 需要
--> 正在处理依赖关系 devtoolset-9-runtime,它被软件包 devtoolset-9-gcc-c++-9.3.1-2.2.el7.x86_64 需要
--> 正在检查事务
---> 软件包 devtoolset-9-gcc.x86_64.0.9.3.1-2.2.el7 将被 安装
--> 正在处理依赖关系 devtoolset-9-binutils >= 2.22.52.0.1,它被软件包 devtoolset-9-gcc-9.3.1-2.2.el7.x86_64 需要
---> 软件包 devtoolset-9-libstdc++-devel.x86_64.0.9.3.1-2.2.el7 将被 安装
---> 软件包 devtoolset-9-runtime.x86_64.0.9.1-0.el7 将被 安装
--> 正在处理依赖关系 scl-utils >= 20120927-11,它被软件包 devtoolset-9-runtime-9.1-0.el7.x86_64 需要
--> 正在检查事务
---> 软件包 devtoolset-9-binutils.x86_64.0.2.32-16.el7 将被 安装
---> 软件包 scl-utils.x86_64.0.20130529-19.el7 将被 安装
--> 解决依赖关系完成

依赖关系解决

==============================================================================================================================================================
 Package                                           架构                        版本                                 源                                   大小
==============================================================================================================================================================
正在安装:
 devtoolset-9-gcc-c++                              x86_64                      9.3.1-2.2.el7                        centos-sclo-rh                       12 M
为依赖而安装:
 devtoolset-9-binutils                             x86_64                      2.32-16.el7                          centos-sclo-rh                      5.9 M
 devtoolset-9-gcc                                  x86_64                      9.3.1-2.2.el7                        centos-sclo-rh                       32 M
 devtoolset-9-libstdc++-devel                      x86_64                      9.3.1-2.2.el7                        centos-sclo-rh                      3.1 M
 devtoolset-9-runtime                              x86_64                      9.1-0.el7                            centos-sclo-rh                       20 k
 scl-utils                                         x86_64                      20130529-19.el7                      base                                 24 k

事务概要
==============================================================================================================================================================
安装  1 软件包 (+5 依赖软件包)

总计:53 M
安装大小:151 M
Downloading packages:
warning: /var/cache/yum/x86_64/7/centos-sclo-rh/packages/devtoolset-9-runtime-9.1-0.el7.x86_64.rpm: Header V4 RSA/SHA1 Signature, key ID f2ee9d55: NOKEY
从 file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7 检索密钥


源 "CentOS-7 - SCLo rh" 的 GPG 密钥已安装,但是不适用于此软件包。请检查源的公钥 URL 是否配置正确。


 失败的软件包是:devtoolset-9-runtime-9.1-0.el7.x86_64
 GPG  密钥配置为:file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

1. 导入 GPG 密钥 

rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-SCLo

2、清理 YUM 缓存并重试安装 

yum clean all
yum -y install devtoolset-9-gcc devtoolset-9-gcc-c++

 成功


 

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值