Linux centos7 安装 yum install epel-release 出现 无需任何处理 提示

转载 : http://www.blogketori.com/wordpress/2020/03/28/%E6%96%B0%E5%88%9D%E5%A7%8B%E5%8C%96%E5%88%B0centos%E5%AE%9E%E4%BE%8B%E6%97%A0%E6%B3%95%E9%80%9A%E8%BF%87yum%E5%AE%89%E8%A3%85epel-release%E7%AD%89%E5%BA%93/

有部分等centos在初始化实例完毕之后是没有配置yum源的,这个时候需要手动配置了

进入

vim /etc/yum.repos.d/epel.repo

在里面输入

[epel]
name=Extra Packages for Enterprise Linux 7 - $basearch
baseurl=http://download.fedoraproject.org/pub/epel/7/$basearch 
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-7&arch=$basearch

failovermethod=priority
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-7

然后切换到目录 /etc/pki/rpm-gpg/

cd /etc/pki/rpm-gpg/

执行下面这段指令

wget https://archive.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7

最终yum install epel-release就可以安装啦!!!

转载地址

  • 3
    点赞
  • 19
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值