Install EPEL repo on Centos

EPEL are Extra Packages for Enterprise Linux.

For EPEL 6 and 7, just execute

yum install epel-release

EPEL 4 and 5 are no longer supported.

An important step after installing the epel repo is to install YUM-Priorities. Do this step before installing any other packages.

yum install yum-priorities -y

Afterwards check if they are really enabled

vi /etc/yum/pluginconf.d/priorities.conf
[main]
enabled = 1

Then take a look at CentOS-Base.repo

 vi /etc/yum.repos.d/CentOS-Base.repo

and give the sources [base], [updates] and [extras] a priority of 1 and [centosplus] and [contrib] a priority of 2.

Finally open

vi /etc/yum.repos.d/epel.repo

and give the sources a priority of 10

Gratz! You have succesfully installed the EPEL repo.

yum update
yum list | grep epel

EPEL Mirror List