Install EPEL Repository on CentOS

Problem

Install EPEL repository to get access to additional packages through yum.

Solution

Extra Packages for Enterprise Linux, or EPEL, is an additional repository that contains an number of useful packages that are unavailable in the standard Red Hat or CentOS repository. Installing EPEL allows a number of useful programs, daemons and utilities to be installed via a simple yum install xx command.

To add EPEL for your version of CentOS, run the following command depending on the version of your OS:

CentOS 5.x

sudo rpm -Uvh http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm

CentOS 6.x

sudo rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm

CentOS 7.x

sudo rpm -Uvh http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm

Error: 404 Not Found

You may get a similar error message:

curl: (22) The requested URL returned error: 404 Not Found
error: skipping http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-7.noarch.rpm - transfer failed

Note the -release-6-7.* instead of -release-6-8.* This means the version of EPEL you are attempting to download has expired. For a simple fix, try incrementing the version number by 1 (i.e. -release-6-8, which is the current version at the time of writing this guide, to -release-6-9).

If that does not help, you need to find the current version of EPEL.


Was this article helpful?

mood_bad Dislike 0
mood Like 2
visibility Views: 10327