Red Hat Enterprise Linux / CentOS Linux Enable EPEL Repository

How to enable EPEL repo ?

32 bit
CentOS 5 x86

[root@localhost ~]# wget http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm

CentOS 6 x86

[root@localhost ~]# wget http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-5.noarch.rpm

64 bit
CentOS 5 x64

[root@localhost ~]# wget http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm

CentOS 6 x64

[root@localhost ~]# wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm

[root@nginx source]# wget http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm

--2012-04-11 18:07:32--  http://download.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
Resolving download.fedoraproject.org... 209.132.181.16, 213.175.193.206, 152.19.134.146, ...
Connecting to download.fedoraproject.org|209.132.181.16|:80... connected.
HTTP request sent, awaiting response... 302 FOUND
Location: http://madura.idrepo.or.id/epel/5/i386/epel-release-5-4.noarch.rpm [following]
--2012-04-11 18:07:33--  http://madura.idrepo.or.id/epel/5/i386/epel-release-5-4.noarch.rpm
Resolving madura.idrepo.or.id... 203.34.118.132
Connecting to madura.idrepo.or.id|203.34.118.132|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12232 (12K) [application/x-redhat-package-manager]
Saving to: `epel-release-5-4.noarch.rpm'

100%[============================================================>] 12,232      --.-K/s   in 0.01s

2012-04-11 18:07:33 (946 KB/s) - `epel-release-5-4.noarch.rpm' saved [12232/12232]

Install EPEL Repository

[root@nginx source]# rpm -Uvh epel-release-5-4.noarch.rpm

warning: epel-release-5-4.noarch.rpm: Header V3 DSA signature: NOKEY, key ID 217521f6
Preparing...                ########################################### [100%]
   1:epel-release           ########################################### [100%]

Check EPEL Repository include yum repository

[root@nginx source]# yum repolist

Loaded plugins: fastestmirror
Determining fastest mirrors
 * base: centos.idrepo.or.id
 * epel: sulawesi.idrepo.or.id
 * extras: centos.idrepo.or.id
 * updates: centos.idrepo.or.id
base                                                                         | 1.1 kB     00:00
base/primary                                                                 | 967 kB     00:01
base                                                                                      2725/2725
epel                                                                         | 3.4 kB     00:00
epel/primary_db                                                              | 3.1 MB     00:03
extras                                                                       | 2.1 kB     00:00
extras/primary_db                                                            | 166 kB     00:00
updates                                                                      | 1.9 kB     00:00
updates/primary_db                                                           | 190 kB     00:00
repo id                     repo name                                         status
base                        CentOS-5 - Base                                   enabled: 2,725
epel                        Extra Packages for Enterprise Linux 5 - i386      enabled: 5,618
extras                      CentOS-5 - Extras                                 enabled:   276
updates                     CentOS-5 - Updates                                enabled:   214
repolist: 8,833

Check file yum repository

[root@nginx source]# ls -la /etc/yum.repos.d/

total 60
drwxr-xr-x  2 root root 4096 Apr 11 18:19 .
drwxr-xr-x 75 root root 4096 Apr 11 17:57 ..
-rw-r--r--  1 root root 1926 Feb  8  2011 CentOS-Base.repo
-rw-r--r--  1 root root  631 Feb  8  2011 CentOS-Debuginfo.repo
-rw-r--r--  1 root root  626 Feb  8  2011 CentOS-Media.repo
-rw-r--r--  1 root root 4663 Feb  8  2011 CentOS-Vault.repo
-rw-r--r--  1 root root  954 Aug 12  2010 epel.repo
-rw-r--r--  1 root root 1054 Aug 12  2010 epel-testing.repo

Source : cybercity

Leave a Reply

Your email address will not be published.