How to fix GPG key retrieval failed: [Errno 14]? yum install

It is often the case when you try to install a package that the gpg keys are changed or not working anymore. Below is such an error that might show up:

The GPG keys listed for the "MySQL 5.7 Community Server" repository are already installed but they are not correct for this package. Check that the correct key URLs are configured for this repository.

 

You have several options to fix this:

  1. Disable the gpg check in the repository by changing "gpgcheck=1" into "gpgcheck=0"
  2. Reimport the key using below command:
    rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
    You might need to redownload the latest key for the repo, in this case from:
    https://repo.mysql.com/RPM-GPG-KEY-mysql
  • how to fix, gpg, key, retrieval failed, yum
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

 Centos 8 to Centos 8 Stream migration

Update CentOS 8 to latest available version using command: $ sudo dnf update After updating the...

 Count the amount of inodes - files in a given directory

#!/bin/bash## @title inodes#...

 cve-2021-3156 vulnerability

Qualys Security Advisory Baron Samedit: Heap-based buffer overflow in Sudo (CVE-2021-3156)...

 Docker failed with the error: Error response from daemon: error creating overlay mount to invalid argument

If you receive below  error when trying to configure a docker application: Docker failed with...

 Fail2ban high memory usage

The initial fail2ban virtual memory overhead on the server was approximately 350MB.While that is...