How To Enable EPEL Repository On CentOS 8 / RHEL 8

ADVERTISEMENT

Enable EPEL Repository On CentOS 8 / RHEL 8
Enable EPEL Repository On CentOS 8 / RHEL 8

Extra Packages for Enterprise Linux (EPEL) is a package repository that provides additional packages that are not included in standard RHEL / CentOS repositories.

Fedora community maintains the EPEL repository.

This guide helps you how to enable EPEL repository on CentOS 8 / RHEL 8.

THIS DOCUMENT IS ALSO AVAILABLE FOR

CentOS 7  RHEL 7

Enable EPEL Repository

The EPEL repository can be enabled by installing EPEL repository configuration rpm.

CentOS 8

dnf install -y epel-release

The output will look like below

Last metadata expiration check: 0:17:48 ago on Wed 18 Sep 2019 05:46:56 AM UTC. Dependencies resolved.
=================================================================================================================== Package Arch Version Repository Size
===================================================================================================================
Installing: epel-release noarch 8-5.el8 extras 22 k Transaction Summary
===================================================================================================================
Install 1 Package Total download size: 22 k
Installed size: 30 k
Downloading Packages:
epel-release-8-5.el8.noarch.rpm 195 kB/s | 22 kB 00:00 -------------------------------------------------------------------------------------------------------------------
Total 16 kB/s | 22 kB 00:01 Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction Preparing : 1/1 Installing : epel-release-8-5.el8.noarch 1/1 Running scriptlet: epel-release-8-5.el8.noarch 1/1 Verifying : epel-release-8-5.el8.noarch 1/1 Installed: epel-release-8-5.el8.noarch Complete!

Additionally, enable the PowerTools repository since EPEL packages may depend on packages from it.

dnf config-manager --set-enabled PowerTools

RHEL 8

dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm

The output will look like below

Last metadata expiration check: 0:17:48 ago on Wed 18 Sep 2019 05:46:56 AM UTC.
epel-release-latest-8.noarch.rpm 15 kB/s | 21 kB 00:01 Dependencies resolved.
=================================================================================================================== Package Arch Version Repository Size
===================================================================================================================
Installing: epel-release noarch 8-5.el8 @commandline 21 k Transaction Summary
===================================================================================================================
Install 1 Package Total size: 21 k
Installed size: 30 k
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction Preparing : 1/1 Installing : epel-release-8-5.el8.noarch 1/1 Running scriptlet: epel-release-8-5.el8.noarch 1/1 Verifying : epel-release-8-5.el8.noarch 1/1 Installed: epel-release-8-5.el8.noarch Complete!

Additionally, enable Code ready builder repository on RHEL 8 since EPEL packages may depend on packages from it.

ARCH=$( /bin/arch ) subscription-manager repos --enable "codeready-builder-for-rhel-8-${ARCH}-rpms"

List Repositories

You can find the EPEL repository in the list.

dnf repolist

The output will look like below

repo id repo name status
AppStream CentOS-8 - AppStream 4,933
BaseOS CentOS-8 - Base 1,784
PowerTools CentOS-8 - PowerTools 1,462
*epel Extra Packages for Enterprise Linux 8 - x86_64 4,426
extras CentOS-8 - Extras 3

List Available Packages On EPEL repository

dnf list available --disablerepo=* --enablerepo=epel

The packages list will look like below.

. . .
. . . zabbix40-server-pgsql.x86_64 4.0.11-2.el8 epel
zabbix40-web.noarch 4.0.11-2.el8 epel
zabbix40-web-mysql.noarch 4.0.11-2.el8 epel
zabbix40-web-pgsql.noarch 4.0.11-2.el8 epel
zerofree.x86_64 1.1.1-3.el8 epel
zimg.x86_64 2.8-4.el8 epel
zimg-devel.x86_64 2.8-4.el8 epel
zvbi.x86_64 0.2.35-9.el8 epel
zvbi-devel.x86_64 0.2.35-9.el8 epel
zvbi-fonts.noarch 0.2.35-9.el8 epel

Search Packages On EPE Repository

You can use the search or list option with dnf command to find packages.

dnf search xrdp

OR

dnf list xrdp

Output:

Available Packages
xrdp.x86_64 1:0.9.11-1.el8 epel

Install Packages from EPEL Repository

Installing a package from the EPEL repository is a straight forward one. Use the dnf command to install a package.

ADVERTISEMENT

dnf install xrdp

Conclusion

That’s All. I hoper you have learned how to enable EPEL repository on CentOS 8 / RHEL 8. Please share your feedback in the comments section.

Posted by Linux Admin