You are not logged in.
I have no idea how this happened, but my pubring.gpg file size is 0. When I try to revert to my last archlinux-keyring as follows:
sudo pacman -U archlinux-keyring-20230130-1-any.pkg.tar.zst
I get this result:
loading packages...
error: 'archlinux-keyring-20230130-1-any.pkg.tar.zst': invalid or corrupted package (PGP signature)
So, I can't install anything, because pubring.gpg is blank.
$ pacman-key --init
and
$ sudo pacman-key --populate archlinux
don't help either.
How do I solve this?
Last edited by luser (2023-02-25 02:17:39)
luser: an epithet applied by Windows users to linux users
Offline
Well, being an impatient human, I monkeyed around with it, performing the following steps, which seems to have resolved the issue:
# rm -r /etc/pacman.d/gnupg/
# pacman-key --init
# pacman-key --populate archlinux
This appears to have resolved my problem. Frankly, I was afraid to
rm -r /etc/pacman.d/gnupg/
However, Pacman seems to work now. If anyone believes that there was a better way to resolve the issue, please chime in.
luser: an epithet applied by Windows users to linux users
Offline
Offline
@Jason
I tried the things in your link:
# pacman-key --init
# pacman-key --populate
While the first line seemed to work, the latter produced the following output:
==> Appending keys from archlinux.gpg...
==> Disabling revoked keys in keyring...
-> Disabled 34 keys.
==> Updating trust database...
gpg: public key of ultimately trusted key E645B197910C1332 not found
gpg: marginals needed: 3 completes needed: 1 trust model: pgp
gpg: depth: 0 valid: 2 signed: 5 trust: 0-, 0q, 0n, 0m, 0f, 2u
gpg: depth: 1 valid: 5 signed: 95 trust: 5-, 0q, 0n, 0m, 0f, 0u
gpg: next trustdb check due at 2023-07-12
==> ERROR: Trust database could not be updated.
. . . and it didn't solve the problem, so I tried:
$ sudo pacman-key --populate archlinux
which didn't produce an error, BUT, it didn't solve the problem either. Immediately after, I tried reinstalling the archlinux-keyring. . .
$ sudo pacman -S archlinux-keyring
warning: archlinux-keyring-20230223-1 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...
Packages (1) archlinux-keyring-20230223-1
Total Installed Size: 1.60 MiB
Net Upgrade Size: 0.00 MiB
:: Proceed with installation? [Y/n]
(1/1) checking keys in keyring [####################################] 100%
(1/1) checking package integrity [####################################] 100%
error: archlinux-keyring: signature from "Morten Linderud <morten@linderud.pw>" is unknown trust
:: File /var/cache/pacman/pkg/archlinux-keyring-20230223-1-any.pkg.tar.zst is corrupted (invalid or corrupted package (PGP signature)).
Do you want to delete it? [Y/n]
error: failed to commit transaction (invalid or corrupted package (PGP signature))
Errors occurred, no packages were upgraded.
So, that didn't work, either.
At this point, I'm just wondering whether there was any cost to deleting /etc/pacman.d/gnupg that I am unaware of. Running pacman-key --init and pacman-key --populate without deleting the folder didn't get the job done.
Last edited by luser (2023-02-25 02:57:27)
luser: an epithet applied by Windows users to linux users
Offline
Remove or reset all the keys installed in your system by removing the /etc/pacman.d/gnupg directory (as root) and by rerunning pacman-key --init followed by pacman-key --populate to re-add the default keys.
Offline