1、RHEL/CentOS/SL Linux 6.x 下安装 EPEL6 yum源:
32位系统选择:
rpm -ivhhttp://download.fedora.redhat.com/pub/epel/6/i386/epel-release-6-5.noarch.rpm
64位系统选择:
rpm -ivhhttp://download.fedora.redhat.com/pub/epel/6/x86_64/epel-release-6-5.noarch.rpm //我试了这个竟然出错了.
导入key:rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
2、默认会在/etc/yum.repos.d/下创建epel.repo和epel-testing.repo两个配置文件,epel.repo的内容如下:
[epel]
name=Extra Packages for Enterprise Linux 6 – $basearch
#baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-6&arch=$basearch
failovermethod=priority
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6[epel-debuginfo]
name=Extra Packages for Enterprise Linux 6 – $basearch –Debug
#baseurl=http://download.fedoraproject.org/pub/epel/6/$basearch/debug
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-debug-6&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
gpgcheck=1[epel-source]
name=Extra Packages for Enterprise Linux 6 – $basearch –Source
#baseurl=http://download.fedoraproject.org/pub/epel/6/SRPMS
mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=epel-source-6&arch=$basearch
failovermethod=priority
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
gpgcheck=1
如果想使用比较新的软件,可以启用[epel-testing]源,把里面的enabled=0改成enabled=1就可以。
3、yum安装nginx测试看看:
yum install nginx
yum install -y trickle ///trickle is a nice tool! Try it!