{"id":3749,"date":"2024-06-06T18:55:53","date_gmt":"2024-06-06T13:25:53","guid":{"rendered":"https:\/\/www.veeble.org\/kb\/?p=3749"},"modified":"2025-04-09T12:19:23","modified_gmt":"2025-04-09T06:49:23","slug":"fix-almalinux-gpg-key-error","status":"publish","type":"post","link":"https:\/\/www.veeble.com\/kb\/fix-almalinux-gpg-key-error\/","title":{"rendered":"How to Fix &#8216;Error: GPG check FAILED&#8217; Alma Linux"},"content":{"rendered":"\n<figure class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration.jpg\" target=\"_blank\" rel=\"noopener\"><img fetchpriority=\"high\" decoding=\"async\" width=\"1080\" height=\"411\" data-id=\"3750\" src=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration.jpg\" alt=\"GPG Keys are configured as: file:\/\/\/etc\/pki\/rpm-gpg\/RPM-GPG-KEY-AlmaLinux\" class=\"wp-image-3750\" srcset=\"https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration.jpg 1080w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration-300x114.jpg 300w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration-1024x390.jpg 1024w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Fixing-GPG-Keys-Configuration-768x292.jpg 768w\" sizes=\"(max-width: 1080px) 100vw, 1080px\" \/><\/a><\/figure>\n<\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>On a Linux system, such as AlmaLinux, a <a href=\"https:\/\/en.wikipedia.org\/wiki\/GNU_Privacy_Guard\" target=\"_blank\" rel=\"noopener\">GPG (GNU Privacy Guard)<\/a> key is used to confirm the integrity and validity of packages before installing or updating software. The GPG key verifies that packages have not been altered and are from a reliable source when you install or upgrade them. The current GPG key used to sign packages for AlmaLinux 8 expired in January 2024. Therefore most of the Almalinux 8 users which uses package versions lower than <code>8.8-3.el8 <\/code>may find an error when trying to update or install packages. This error will be like &#8216;GPG Keys are configured as: file:\/\/\/etc\/pki\/rpm-gpg\/RPM-GPG-KEY-AlmaLinux&#8217;. or &#8216;Error: GPG check FAILED&#8217;<br>To resolve this and update or install packages, users need to import the correct GPG Key. This tutorial presents a simple approach to fix this issue and stabilize your system.<\/p>\n\n\n\n<p><\/p>\n\n\n<h4 class=\"wp-block-heading\" id=\"refresh-the-repository\">Refresh the Repository<\/h4>\n\n\n<p>Refreshing the <a href=\"https:\/\/www.veeble.org\/kb\/almalinux-yum-repository-list-working-urls\/\" target=\"_blank\" rel=\"noopener\">Almalinux repository<\/a> can solve the errors related to GPG keys by ensuring that the package manager retrieves the latest metadata and package information, including the GPG keys, from the repository. This method is not always a success but it may sometimes fix the issue:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>yum clean all\nyum makecache<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-2 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805.png\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" width=\"1121\" height=\"167\" data-id=\"3760\" src=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805.png\" alt=\"refresh yum repositories\" class=\"wp-image-3760\" srcset=\"https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805.png 1121w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805-300x45.png 300w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805-1024x153.png 1024w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-190805-768x114.png 768w\" sizes=\"(max-width: 1121px) 100vw, 1121px\" \/><\/a><\/figure>\n<\/figure>\n\n\n\n<p><\/p>\n\n\n<h4 class=\"wp-block-heading\" id=\"importing-correct-master-gpg-key\">Importing Correct Master GPG Key<\/h4>\n\n\n<p>The primary method for resolving this issue was to import GPG keys. To prevent encountering errors during updates or installations of AlmaLinux 8 packages, execute the following command to import the correct master key:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>rpm --import https:\/\/repo.almalinux.org\/almalinux\/RPM-GPG-KEY-AlmaLinux<\/code><\/pre>\n\n\n\n<p>This command will execute without any outputs!<\/p>\n\n\n<h4 class=\"wp-block-heading\" id=\"upgrade-the-almalinux-release-package\">Upgrade the AlmaLinux Release Package<\/h4>\n\n\n<p>After importing the master GPG key, it is advised to upgrade Almalinux release packages. Upgrading the AlmaLinux release package ensures the new GPG key is properly integrated, repository configurations are updated, and the system maintains security and operational standards for seamless future updates. To upgrade it, execute the command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>dnf upgrade almalinux-release<\/code><\/pre>\n\n\n\n<figure class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-3 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303.png\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" width=\"1099\" height=\"750\" data-id=\"3753\" src=\"https:\/\/www.veeble.org\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303.png\" alt=\"GPG Keys are configured as: file:\/\/\/etc\/pki\/rpm-gpg\/RPM-GPG-KEY-AlmaLinux\" class=\"wp-image-3753\" srcset=\"https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303.png 1099w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303-300x205.png 300w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303-1024x699.png 1024w, https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/Screenshot-2024-06-06-153303-768x524.png 768w\" sizes=\"(max-width: 1099px) 100vw, 1099px\" \/><\/a><\/figure>\n<\/figure>\n\n\n\n<p><\/p>\n\n\n<h4 class=\"wp-block-heading\" id=\"how-to-test-everything-working\">How to Test Everything Working?<\/h4>\n\n\n<p>Finally, to test if the GPG key issue is resolved, simply install a package or update your AlmaLinux system. If no errors like &#8216;GPG Keys configured as: file:\/\/\/etc\/pki\/rpm-gpg\/RPM-GPG-KEY-AlmaLinux&#8217; occur during these operations, it indicates the successful resolution of the issue.<\/p>\n\n\n\n<p>For example, to install a package:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>yum install <em>package-name<\/em><\/code><\/pre>\n\n\n\n<div class=\"wp-block-uagb-separator uagb-block-77c94504\"><div class=\"wp-block-uagb-separator__inner\" style=\"--my-background-image:\"><\/div><\/div>\n\n\n\n<p>Regularly verifying and updating GPG keys in your system administration routine is vital to protect the package management integrity. By prioritizing these security measures, you can mitigate potential risks and ensure a robust foundation for your AlmaLinux system.<\/p>\n\n\n\n<div style=\"height:40px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<div class=\"wp-block-uagb-call-to-action uagb-block-8b5641e7 wp-block-button\"><div class=\"uagb-cta__wrap\"><h3 class=\"uagb-cta__title\">Simplify Your AWS Journey with Veeble<\/h3><p class=\"uagb-cta__desc\">From migration to ongoing management, Veeble simplifies every step of your AWS journey, making it easier than ever to leverage the power of the cloud.<\/p><\/div><div class=\"uagb-cta__buttons\"><a href=\"https:\/\/www.veeble.com\/in\/managed-aws-hosting\/\" class=\"uagb-cta__button-link-wrapper wp-block-button__link\" target=\"_blank\" rel=\"noopener noreferrer\">Start My AWS Journey<svg xmlns=\"https:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\"><path d=\"M504.3 273.6l-112.1 104c-6.992 6.484-17.18 8.218-25.94 4.406c-8.758-3.812-14.42-12.45-14.42-21.1L351.9 288H32C14.33 288 .0002 273.7 .0002 255.1S14.33 224 32 224h319.9l0-72c0-9.547 5.66-18.19 14.42-22c8.754-3.809 18.95-2.075 25.94 4.41l112.1 104C514.6 247.9 514.6 264.1 504.3 273.6z\"><\/path><\/svg><\/a><\/div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>On a Linux system, such as AlmaLinux, a GPG (GNU Privacy Guard) key is used to confirm the integrity and validity of packages before [&hellip;]<\/p>\n","protected":false},"author":7,"featured_media":8521,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_uag_custom_page_level_css":"","site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"set","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[5,3],"tags":[],"class_list":["post-3749","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","category-installation"],"uagb_featured_image_src":{"full":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux.jpg",1536,1024,false],"thumbnail":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux-150x150.jpg",150,150,true],"medium":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux-300x200.jpg",300,200,true],"medium_large":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux-768x512.jpg",768,512,true],"large":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux-1024x683.jpg",1024,683,true],"1536x1536":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux.jpg",1536,1024,false],"2048x2048":["https:\/\/www.veeble.com\/kb\/wp-content\/uploads\/2024\/06\/How-to-Fix-Error-GPG-check-FAILED-AlmaLinux.jpg",1536,1024,false]},"uagb_author_info":{"display_name":"Adrian Antony","author_link":"https:\/\/www.veeble.com\/kb\/author\/adrian\/"},"uagb_comment_info":0,"uagb_excerpt":"On a Linux system, such as AlmaLinux, a GPG (GNU Privacy Guard) key is used to confirm the integrity and validity of packages before [&hellip;]","_links":{"self":[{"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/posts\/3749","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/comments?post=3749"}],"version-history":[{"count":19,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/posts\/3749\/revisions"}],"predecessor-version":[{"id":8522,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/posts\/3749\/revisions\/8522"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/media\/8521"}],"wp:attachment":[{"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/media?parent=3749"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/categories?post=3749"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.veeble.com\/kb\/wp-json\/wp\/v2\/tags?post=3749"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}