当前位置: > CentOS > CentOS教程 >

CentOS7/RHEL7安装EPEL

时间:2015-03-05 14:14来源:linux.it.net.cn 作者:IT
EPEL,即Extra Packages for Enterprise Linux的简称,是为企业级Linux提供的一组高质量的额外软件包,包括但不限于Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL), Oracle Enterprise Linux (OEL)。(关于 : EPEL)

为CentOS7/RHEL7安装EPEL 仓库(repo)

方法一:命令安装

123456789101112131415161718192021222324252627282930313233343536373839 [root@idoseek ~]# yum -y install epel-release已加载插件:fastestmirrorLoading mirror speeds from cached hostfile * base: mirrors.unifiedlayer.com * extras: mirrors.kernel.org * updates: mirrors.syringanetworks.net正在解决依赖关系--> 正在检查事务---> 软件包 epel-release.noarch.0.7-2 将被 安装--> 解决依赖关系完成 依赖关系解决 ==================================================================================================== Package                     架构                  版本                 源                     大小====================================================================================================正在安装: epel-release                noarch                7-2                  extras                 13 k 事务概要====================================================================================================安装  1 软件包 总下载量:13 k安装大小:22 kDownloading packages:epel-release-7-2.noarch.rpm                                                  |  13 kB  00:00:00     Running transaction checkRunning transaction testTransaction test succeededRunning transaction  正在安装    : epel-release-7-2.noarch                                                         1/1   验证中      : epel-release-7-2.noarch                                                         1/1  已安装:  epel-release.noarch 0:7-2                                                                          完毕![root@idoseek ~]#
方法二:手动安装

针对系统架构选择相应的类型:http://dl.fedoraproject.org/pub/epel/7/。我们使用的x86_64,就要进入该目录下寻找相应包,安装方法如下:

1 # rpm -vih http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm
或者:

12 # wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm# rpm -vih epel-release-7-2.noarch.rpm
更新包缓存

此时我们发现/etc/yum.repos.d/下多了两个epel的repo文件:

123456789 [root@idoseek ~]# ll /etc/yum.repos.d/总用量 28-rw-r--r-- 1 root root 1664 8月  22 12:21 CentOS-Base.repo-rw-r--r-- 1 root root  649 8月  22 12:21 CentOS-Debuginfo.repo-rw-r--r-- 1 root root  290 8月  22 12:21 CentOS-fasttrack.repo-rw-r--r-- 1 root root 1331 8月  22 12:21 CentOS-Sources.repo-rw-r--r-- 1 root root  156 8月  22 12:21 CentOS-Vault.repo-rw-r--r-- 1 root root  957 9月   2 12:14 epel.repo-rw-r--r-- 1 root root 1056 9月   2 12:14 epel-testing.repo
更新元数据缓存:

1 [root@idoseek ~]# yum clean all && yum makecache
(责任编辑:IT)
------分隔线----------------------------
栏目列表
推荐内容