【阿里云镜像】配置阿里云RepoForge 镜像
程序员文章站
2022-03-07 19:20:58
...
一、参考链接
阿里巴巴开源镜像站-OPSX镜像站-阿里云开发者社区 (aliyun.com)
repoforge镜像-repoforge下载地址-repoforge安装教程-阿里巴巴开源镜像站 (aliyun.com)
二、RepoForge 镜像介绍
Repoforge 是 RHEL 系统下的软件仓库,拥有 10000 多个软件包,被认为是最安全、最稳定的一个软件仓库。
下载地址:https://mirrors.aliyun.com/repoforge/
三、RepoForge 镜像配置
1、运行uname 获取 OS 版本号(如 EL6, EL7 等)
[root@centos ~]# uname -aLinux centos 3.10.0-1160.el7.x86_64 #1 SMP Mon Oct 19 16:18:59 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
2、向系统中添加 Repoforge 的 GPG 公钥
[root@centos ~]# rpm --import https://mirrors.aliyun.com/repoforge/RPM-GPG-KEY.dag.txt[root@centos ~]#
3、运行下列命令(以 OS 版本 7 为例):
sudo cat > /etc/yum.repos.d/rpmforge.repo << EOF[rpmforge]name = RHEL $releasever - RPMforge.net - dagbaseurl = https://mirrors.aliyun.com/repoforge/redhat/el7/en/$basearch/rpmforgemirrorlist = http://mirrorlist.repoforge.org/el7/mirrors-rpmforgeenabled = 1protect = 0gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-daggpgcheck = 1[rpmforge-extras]name = RHEL $releasever - RPMforge.net - extrasbaseurl = https://mirrors.aliyun.com/repoforge/redhat/el7/en/$basearch/extrasmirrorlist = http://mirrorlist.repoforge.org/el7/mirrors-rpmforge-extrasenabled = 0protect = 0gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-daggpgcheck = 1[rpmforge-testing]name = RHEL $releasever - RPMforge.net - testingbaseurl = https://mirrors.aliyun.com/repoforge/redhat/el7/en/$basearch/testingmirrorlist = http://mirrorlist.repoforge.org/el7/mirrors-rpmforge-testingenabled = 0protect = 0gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-daggpgcheck = 1EOF
4、更新YUM源
[root@centos ~]# yum repolistLoaded plugins: fastestmirror, versionlockLoading mirror speeds from cached hostfile * base: mirrors.aliyun.com * extras: mirrors.aliyun.com * rpmforge: mirrors.aliyun.com * updates: mirrors.aliyun.comrepo id repo name statusbase/7/x86_64 CentOS-7 - Base - mirrors.aliyun.com 10,072extras/7/x86_64 CentOS-7 - Extras - mirrors.aliyun.com 500rpmforge RHEL - RPMforge.net - dag 245updates/7/x86_64 CentOS-7 - Updates - mirrors.aliyun.com 3,242repolist: 14,059[root@centos ~]#