Ubuntu Version: 22.04.02 LTS
Desktop Environment (if applicable): KDE Plasma
Problem Description: With apt update I get error messages all related to the same public key
Relevant System Information:
Screenshots or Error Messages:
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ports.ubuntu.com/ubuntu-ports noble InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C
E: http://ports.ubuntu.com/ubuntu-ports noble InRelease is not (yet) available (The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ports.ubuntu.com/ubuntu-ports noble-updates InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C
E: http://ports.ubuntu.com/ubuntu-ports noble-updates InRelease is not (yet) available (The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C)
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://ports.ubuntu.com/ubuntu-ports noble-security InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C
E: http://ports.ubuntu.com/ubuntu-ports noble-security InRelease is not (yet) available (The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 871920D1991BC93C)
What I’ve Tried:
I searched and found the same problem in different places. Mostly the solution provided is using apt-key add
but this is depricated now. I have tried a lot of things but I hasn’t helped. What I have done is:
sudo gpg --keyserver keyserver.ubuntu.com --recv-key 871920D1991BC93C
but the key seems to be already there:
gpg: key 871920D1991BC93C: "Ubuntu Archive Automatic Signing Key (2018) <ftpmaster@ubuntu.com>" not changed
gpg: Total number processed: 1
gpg: unchanged: 1
The contents of /etc/apt/sources.list.d/ubuntu.sources
is as follows:
Types: deb
URIs: http://ports.ubuntu.com/ubuntu-ports/
Suites: noble noble-updates noble-security
Components: main restricted universe multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
contents of /usr/share/keyrings
docker.gpg ubuntu-master-keyring.gpg ubuntu-pro-esm-infra.gpg
ubuntu-archive-keyring.gpg ubuntu-pro-anbox-cloud.gpg ubuntu-pro-fips-preview.gpg
ubuntu-archive-removed-keys.gpg ubuntu-pro-cc-eal.gpg ubuntu-pro-fips.gpg
ubuntu-cloudimage-keyring.gpg ubuntu-pro-cis.gpg ubuntu-pro-realtime-kernel.gpg
ubuntu-cloudimage-removed-keys.gpg ubuntu-pro-esm-apps.gpg ubuntu-pro-ros.gpg
contents of /etc/apt/trusted.gpg.d
riot.gpg~ ubuntu-keyring-2012-cdimage.gpg~ ubuntu-ports.gpg
ubuntu-archive.gpg ubuntu-keyring-2018-archive.gpg~ ubuntu.gpg~
I don’t know why there are keys in different places and what I am supposed to do to make apt use the public key I seem to have already.
apt update
shows the errors above.