Centos epel repository in CentOS 5.x and 6.x

 

centos-epel-repository

In Following post You will be able to enableĀ Centos epel repository in CentOS 5.x and 6.x versions.

We start with CentOS 5.x version, first we will download rpm package and then install it,

wget http://dl.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-5.rpm
sudo rpm -Uvh remi-release-5*.rpm epel-release-5*.rpm (if not root then use sudo otherwise with root user you don’t need to add sudo)

Now, for CentOS 6.x,

wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm

After installation you can verify new repositories by,

#ls -l /etc/yum.repos.d/epel* /etc/yum.repos.d/remi.repo
/etc/yum.repos.d/epel.repo
/etc/yum.repos.d/epel-testing.repo
/etc/yum.repos.d/remi.repo

now to enable remi repo you need to do following changes in file,

#vim /etc/yum.repos.d/remi.repo

name=Les RPM de remi pour Enterprise Linux $releasever - $basearch
#baseurl=http://rpms.famillecollet.com/enterprise/$releasever/remi/$basearch/
mirrorlist=http://rpms.famillecollet.com/enterprise/$releasever/remi/mirror
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi
failovermethod=priority

that's it. Now you can have wide range of yum updates.