I want to enable the Extra Packages for Enterprise Linux (EPEL) repository (repo) to allow installation of packages that are not available in standard repositories.
Standard repositories might not provide packages that need to be installed on Centos, Red Hat Enterprise Linux (RHEL), or Amazon Linux-based distributions. Enabling the EPEL repo provides additional package installation options.
Follow these steps to download, install, and enable the EPEL repo on Centos, RHEL, or Amazon Linux-based distributions:
1. Install and enable the EPEL rpm package that corresponds to your system architecture.
sudo yum install –y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo yum install –y https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
Centos 7 64-bit, Centos 6 64-bit, and Centos 6 32-bit
sudo yum install –y epel-release
Amazon Linux – The EPEL repo is already installed on Amazon Linux, but it must be enabled by updating the epel.repo file. The following command illustrates use of the vim editor to update the epel.repo file.
a. Locate and change the entry enabled=0 to enabled=1 that is located in the $basearch section of the epel.repo file.
b. Save and exit the vim editor.
After making this change, press SHIFT + : [colon] to open a new command entry box in the vim editor. Type wq, and then press Enter to save changes and exit vim.
Alternatively, you can use the yum-config-manager command to enable the EPEL repo on Amazon Linux without manually editing the epel.repo file:
sudo yum-config-manager --enable epel
2. To verify that the EPEL repo is enabled, run the following command:
sudo yum repolist
EPEL should now be used to search installed packages. Optionally, if you want to ensure EPEL is being polled directly, you can attempt to install zabbix (or one of the many other applications that are available for download from the epel repository).
sudo yum –-enablerepo=epel install zabbix
Amazon EC2, Linux, enable EPEL repo, repository, RHEL, Centos, epel.repo, yum-config-manager, AMI