Will's avatar

⬅️ See more posts

Pacman: signature is unknown trust

19 September 2021 (1 minute read)

🔮 This post is also available via Gemini.

100daystooffload technology

💯 100 Days to Offload

This article is one of a series of posts I have written for the 100 Days to Offload challenge. Disclaimer: The challenge focuses on writing frequency rather than quality, and so posts may not always be fully planned out!

View other posts in this series.

I was performing a standard system upgrade on an Arch server this morning and received the following messages (maintainer details redacted):

$ sudo pacman -Syyu

... # Download of packages

(159/159) checking keys in keyring                 [######################] 100%
(159/159) checking package integrity               [######################] 100%
error: fail2ban: signature from "... <...>" is unknown trust
:: File /var/cache/pacman/pkg/fail2ban-0.11.2-2-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)
Errors occurred, no packages were upgraded.

I followed advice in the forums and tried refreshing and repopulating the keys, clearing the Pacman cache, and a combination of these things. I still kept getting the same problem each time I tried to upgrade.

Eventually I just removed the package, ran the upgrade, and then re-installed it:

$ sudo pacman -R fail2ban
$ sudo pacman -Syyu
$ sudo pacman -S fail2ban

That fixed the problem, but I’m still not really sure why re-fetching the keys manually didn’t help!

✉️ You can reply to this post via email.

📲 Subscribe to updates

If you would like to read more posts like this, then you can subscribe via RSS.