Yum repolist results in "Failed to download gpg key for repo" error

Solution Verified - Updated -

Issue

  • Unable to run yum update on the RHEL system.
  • Yum repolist fails with GPG errors
  • Unable to access Red Hat repositories
  • Yum repolist results in "Failed to download gpg key for repo 'PowerTools':Curl error(37):Couldn't read a file:// file for file:///etc/pki/rpm-gpg/RPM-GPG-KEY-centosoffical[Couldn't open file /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial]" error

Environment

  • Red Hat Enterprise Linux

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content