How to Enable The Epel Respository with RPM
The Epel respository offers CentOS and RHEL the ability to you the Fedora Extra Packages for Enterprise Linux, which includes many useful packages such as HAProxy and others.
Install with yum
Run the following as root or with sudo:
yum -y install epel-release
Install with RPM
Sometimes you may not be able to install with yum, in that case you can install with RPM instead.
CentOS and Red Hat Enterprise Linux 5.x
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-5.noarch.rpm rpm -Uvh epel-release-5*.rpm
CentOS and Red Hat Enterprise Linux 6.x
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm rpm -Uvh epel-release-6*.rpm
CentOS and Red Hat Enterprise Linux 7.x
wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm rpm -Uvh epel-release-7*.rpm