How to enable epel repository on RHEL/CentOS 6.x versions ?

In this post, we will see how to enable EPEL repository on RHEL/CentOS 6.x versions.

We will take an example of 6.8 version, similarly you can change your version and download different rpm version.

1. Download the rpm to auto configure the epel repo.

[root@ngelinux001 yum.repos.d]# wget https://archives.fedoraproject.org/pub/archive/epel/6/x86_64/epel-release-6-8.noarch.rpm
--2022-05-27 21:20:15--  https://archives.fedoraproject.org/pub/archive/epel/6/x86_64/epel-release-6-8.noarch.rpm
Resolving archives.fedoraproject.org... 38.145.60.24, 38.145.60.22, 38.145.60.23
Connecting to archives.fedoraproject.org|38.145.60.24|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 14540 (14K) [application/x-rpm]
Saving to: “epel-release-6-8.noarch.rpm”

100%[======================================================================================>] 14,540      66.4K/s   in 0.2s

2022-05-27 21:20:19 (66.4 KB/s) - “epel-release-6-8.noarch.rpm” saved [14540/14540]

[root@ngelinux001yum.repos.d]#

 

2. Upgrade/Install the RPM

[root@ngelinux001 yum.repos.d]# rpm -Uvh ./epel-release-6*.rpm
warning: epel-release-6-8.noarch.rpm: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Preparing...                ########################################### [100%]
   1:epel-release           ########################################### [100%]
[root@ngelinux001yum.repos.d]#

 

3. Now check the repo by enabling it.
It does not work in my case as internet is restricted.

[user@ngelinux001 yum.repos.d]$ yum --enablerepo=* repolist
Loaded plugins: aliases, changelog, downloadonly, kabi, presto, product-id, refresh-packagekit, security, subscription-manager,
              : tmprepo, verify, versionlock
Loading support for Red Hat kernel ABI
addedrepo                                                                                                | 2.9 kB     00:00
base                                                                                                     | 4.1 kB     00:00
Error: Cannot retrieve metalink for repository: epel-testing. Please verify its path and try again
[user@ngelinux001 yum.repos.d]$

In case your repo/mirrorlist does not work.

Visit this page: https://admin.fedoraproject.org/mirrormanager/mirrors/EPEL/6/x86_64

And then click on –> http link –> in front of your nearby country page –> Then go inside epel directory and replace with this path.

0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments