5

Through VirtualBox, even in different machines, I have 2 Ubuntu Server 20.04 instances running with the following info:

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.3 LTS
Release:        20.04
Codename:       focal

Both have MySQL installed with the same instructions that I used since months ago. Suddenly just for one of them when I do sudo apt update appears the following:

Get:2 http://repo.mysql.com/apt/ubuntu focal InRelease [12.9 kB]
Hit:3 http://pe.archive.ubuntu.com/ubuntu focal InRelease
Ign:4 https://packages.erlang-solutions.com/ubuntu focal InRelease
Hit:5 https://packages.erlang-solutions.com/ubuntu focal Release
Get:6 http://pe.archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Err:2 http://repo.mysql.com/apt/ubuntu focal InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 467B942D3A79BD29
Get:9 http://pe.archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Get:10 http://pe.archive.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Hit:7 https://packagecloud.io/rabbitmq/rabbitmq-server/ubuntu focal InRelease
Fetched 349 kB in 3s (133 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://repo.mysql.com/apt/ubuntu focal InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 467B942D3A79BD29
W: Failed to fetch http://repo.mysql.com/apt/ubuntu/dists/focal/InRelease  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 467B942D3A79BD29
W: Some index files failed to download. They have been ignored, or old ones used instead.

Questions

  • Why did do happen this?
  • How to solve it?
4
  • It could be the answer of question 2, but what about the 1? Jan 29 at 13:16
  • It's because you've missing GPG keys.
    – Error404
    Jan 29 at 13:17
  • 1
    But why happened that?, in the same instance many times MySQL was updated without any problem with sudo apt update and later of course with sudo apt upgrade. Why suddenly the GPG keys are missing? Jan 29 at 13:19
  • Well, that's because you did something strange with your system... How can I or anyone tell?
    – Error404
    Jan 29 at 13:20

1 Answer 1

27

You will want to import the missing GPG keys for the repository like this:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 467B942D3A79BD29

Then update:

sudo apt update

You should be good 👍🏻

0

Not the answer you're looking for? Browse other questions tagged or ask your own question.