Unable to upgrade system due to corrupted keyrings

Hi! So I tried to run sudo pacman -Syu but the output shows me this error:

:: Retrieving packages...
 yay-12.3.5-1-x86_64                        2,9 MiB  3,16 MiB/s 00:01 [--------------------------------------] 100%
(1232/1232) checking keys in keyring                                  [--------------------------------------] 100%
(1232/1232) checking package integrity                                [--------------------------------------] 100%
error: arc-gtk-theme-eos: signature from "manuel <manuel@endeavouros.com>" is unknown trust
:: File /var/cache/pacman/pkg/arc-gtk-theme-eos-20221218-2-any.pkg.tar.zst is corrupted (invalid or corrupted package (PGP signature)).

Actions taken so far:

  • Ran sudo pacman -Sy endeavouros-keyring && sudo pacman -Syu
  • Ran pacman-key --init && pacman-key --populate && pacman-key --refresh-keys && pacman -Sy archlinux-keyring

Output from running sudo pacman -Sy endeavouros-keyring:

[alejoeie@dev ~]$ sudo pacman -Sy endeavouros-keyring
:: Synchronizing package databases...
 endeavouros is up to date
 core is up to date
 extra is up to date
 community is up to date
 multilib is up to date
resolving dependencies...
looking for conflicting packages...

Package (1)                      Old Version  New Version  Net Change

endeavouros/endeavouros-keyring  20220614-1   20231222-1     0,00 MiB

Total Installed Size:  0,01 MiB
Net Upgrade Size:      0,00 MiB

:: Proceed with installation? [Y/n] Y
(1/1) checking keys in keyring                                        [--------------------------------------] 100%
(1/1) checking package integrity                                      [--------------------------------------] 100%
error: endeavouros-keyring: signature from "manuel <manuel@endeavouros.com>" is unknown trust
:: File /var/cache/pacman/pkg/endeavouros-keyring-20231222-1-any.pkg.tar.zst is corrupted (invalid or corrupted package (PGP signature)).
Do you want to delete it? [Y/n] 

Output from running sudo pacman-key --refresh-keys:

[alejoeie@dev ~]$ sudo pacman-key --refresh-keys
gpg: key A6234074498E9CEE: "Christian Hesse <eworm@archlinux.org>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1
pub   rsa2048 2011-08-12 [SC]
      02FD1C7A934E614545849F19A6234074498E9CEE
uid           [  full  ] Christian Hesse <eworm@archlinux.org>
sub   rsa2048 2011-08-12 [E]
sub   ed25519 2019-08-29 [S]
sub   cv25519 2019-08-29 [E]

gpg: error retrieving 'george@rawlinson.net.nz' via WKD: Connection refused
gpg: error reading key: Connection refused
gpg: key 25EA6900D9EA5EBC: "George Rawlinson <george@rawlinson.net.nz>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1
pub   ed25519 2016-11-03 [C]
      034D823DA2055BEE6A6BF0BB25EA6900D9EA5EBC
uid           [ unknown] George Rawlinson <george@rawlinson.net.nz>
uid           [  full  ] George Rawlinson <grawlinson@archlinux.org>
sub   ed25519 2016-11-04 [A]
sub   ed25519 2016-11-03 [S]
sub   cv25519 2016-11-04 [E]

gpg: key 07D06351CA5B31BE: "Torsten KeĆ

It remains there with no action so I have to CTRL+C the process to interrupt it.

Thanks in advance for your help.

1 Like

Please refer to:

Thanks, still not working for me :frowning:

Could you be more specific?

What is not working?

We need to see the command and the terminal output.

Did you try this part:

sudo mv /etc/pacman.d/gnupg /root/pacman-key.bak
sudo pacman-key --init
sudo pacman-key --populate archlinux endeavouros
sudo pacman -Syy archlinux-keyring endeavouros-keyring
sudo pacman -Syyu

?

Yes I did. The problem appears when running sudo pacman -Syy archlinux-keyring endeavouros-keyring:

error: endeavouros-keyring: signature from "manuel <manuel@endeavouros.com>" is unknown trust
:: File /var/cache/pacman/pkg/endeavouros-keyring-20231222-1-any.pkg.tar.zst is corrupted (invalid or corrupted package (PGP signature)).
Do you want to delete it? [Y/n] Y
error: failed to commit transaction (invalid or corrupted package (PGP signature))
Errors occurred, no packages were upgraded.

I also checked for my system clock and also removed some pkg cache.

sudo pacman -U /var/cache/pacman/pkg/{archlinux,endeavouros}-keyring*.pkg.tar.zst

Does this work?

It says the following:

[alejoeie@dev ~]$ sudo pacman -U /var/cache/pacman/pkg/{archlinux,endeavouros}-keyring*.pkg.tar.zst
[sudo] password for alejoeie: 
loading packages...
warning: archlinux-keyring-20240609-1 is up to date -- reinstalling
error: '/var/cache/pacman/pkg/endeavouros-keyring*.pkg.tar.zst': could not find or read package

Edit your /etc/pacman.conf and set temporarily SigLevel to TrustAll for

[endeavouros]
SigLevel = PackageRequired
Include = /etc/pacman.d/endeavouros-mirrorlist

Install the keyring:

sudo pacman -Sy endeavouros-keyring

:warning: Change back the SigLevel to PackageRequired For [endeavouros].

Update the system:

sudo pacman -Syu

It works now, thanks!

1 Like

You are welcome! Glad you resolved the issue!

Important

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.