「YUM」- 安装并使用第三方仓库

  CREATED BY JENKINSBOT

问题描述

在系统维护过程中,能用YUM安装绝不使用源码安装。所以,经常需要查找壹些第三方,已查找某些软件包。

本文列举最常用第三方源,通常在涉及某些软件安装时,那些文章会指向该文章。

EPEL – Extra Packages for Enterprise Linux

这是最常见的源,安装也比较简单:

#!/bin/sh

yum install epel-release

REMI Repository

在安装各版本PHP环境时,会使用该源:

#!/bin/sh

# CentOS/RHEL 7
yum install epel-release
wget https://rpms.remirepo.net/enterprise/remi-release-7.rpm
rpm -Uvh remi-release-7.rpm

# CentOS/RHEL 6
yum install epel-release
wget https://rpms.remirepo.net/enterprise/remi-release-6.rpm
rpm -Uvh remi-release-6.rpm

SCL – Software Collections Repository

-「3 Methods To Install Latest Python3 Package On CentOS 6 System
The SCL repository is now maintained by a CentOS SIG, which rebuilds the Red Hat Software Collections and also provides some additional packages of their own.

It contains newer versions of various programs that can be installed alongside existing older packages and invoked by using the scl command.

Run the following command to install Software Collections Repository on CentOS

#!/bin/sh

yum install centos-release-scl

End Point Package Repository

-「End Point Package Repository

For RHEL/CentOS 7

#!/bin/sh

# verify and import the signing key.
cd /tmp
wget https://packages.endpoint.com/endpoint-rpmsign-7.pub
rpm --import endpoint-rpmsign-7.pub
rpm -qi gpg-pubkey-703df089 | gpg --with-fingerprint

# Yum configuration
cd /tmp
wget https://packages.endpoint.com/rhel/7/os/x86_64/endpoint-repo-1.7-1.x86_64.rpm
yum localinstall endpoint-repo-1.7-1.x86_64.rpm

# clear your local Yum cache
yum clean all

For RHEL/CentOS 6

#!/bin/sh

# verify and import the signing key.
cd /tmp
wget https://packages.endpoint.com/endpoint-rpmsign.pub
rpm --import endpoint-rpmsign.pub
rpm -qi gpg-pubkey-39b577a1 | gpg --with-fingerprint

# Yum configuration
cd /tmp
wget https://packages.endpoint.com/rhel/6/os/x86_64/endpoint-repo-1.6-1.x86_64.rpm
yum localinstall endpoint-repo-1.6-1.x86_64.rpm

# clear your local Yum cache
yum clean all

# backport repositories

所谓反向移植(backport)是把下一版的包移植到当前发行版。

如果想要使用反向移植的包,可以安装:

#!/bin/sh

yum install endpoint-pg83-repo

附加说明

网上有很多介绍第三方源的文章,这里不再一一列举。

参考文献

Top 8 YUM ThirdParty Repositories for CentOS and RHEL