Here we are trying to help you to fix one of the most common Yum install error
Error 1:
yum install php Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile Error: Cannot retrieve metalink for repository: epel. Please verify its path and try again
You should try these steps so that the metalinks can be retried to be downloaded again.
Steps to solve the issue – Cleaning the YUM header database
yum clean all yum search php yum install php
You can see that it is getting downloaded, but you may also be stopped with an error below
GPG error when trying to compare the signature
GPG key retrieval failed: [Errno 14] Could not open/read file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
First see whether the file is there by doing a `ls` as below
ls /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Most probably you may be getting a file not found message. In any case you need to search Google for RPM-GPG-KEY-EPEL-6 . You will get the GPG key from internet which you can import as below
Importing GPG Key
wget --no-check-certificate https://fedoraproject.org/static/0608B895.txt mv 0608B895.txt /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Even if you download you can still proceed with yum install and it will auto import the key, once found, like below
Auto Importing if present
Total size: 27 M
Is this ok [y/N]: y
Downloading Packages:
warning: rpmts_HdrFromFdno: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Importing GPG key 0x0608B895:
Userid: “EPEL (6) <epel@fedoraproject.org>”
From : /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6
Is this ok [y/N]: y