How to enable EPEL repository on RHEL so I can upgrade Apache [duplicate]
I want to upgrade Apache to 2.4.46 or later on RHEL 7. One step in the instructions I'm following is to Enable the EPEL repository, like so...
cd /etc/yum.repos.d && wget http://mirror.centos.org/centos/7/os/x86_64/repodata/repomd.xml`rpm -q --qf "%{VERSION}" $(rpm -q --whatprovides redhat-release)`.repo
The mirror is not available, so I get a 404, but I also tried using other mirrors and I still get a 404 error. How do I enable the EPEL repo on RHEL 7?
Solution 1:
That's a pretty nasty error in that tutorial. That entire step is wrong and should be skipped. For posterity, it says:
- Enable EPEL Repository
Run the following command to enable EPEL repository for CentOS 7. You can get all CentOS 7 repos at http://mirror.centos.org/centos/7/
# cd /etc/yum.repos.d && wget http://mirror.centos.org/centos/7/os/x86_64/repodata/repomd.xml`rpm -q --qf "%{VERSION}" $(rpm -q --whatprovides redhat-release)`.repo
The epel-release
package ships with the repo already enabled, so it isn't clear what they were aiming at here. In any case, if you have already installed epel-release
, then move on.
You can find accurate official instructions for installing EPEL at its home page.