4

The MySQL repository key has suddenly expired again, so I get a GPG error in Ubuntu when running apt-get update

The error is W: GPG error: http://repo.mysql.com/apt/ubuntu xenial InRelease: The following signatures were invalid: KEYEXPIRED 1550412832 KEYEXPIRED 1550412832 KEYEXPIRED 1550412832

5

TLDR; The one-liner that fixes this is the following:

sudo apt-key adv --recv-keys --keyserver ha.pool.sks-keyservers.net 5072E1F5

Which basically fetches the new key and installs it into the keyring.

A bit more detail:

You can find the expired key by executing the following command:

LANG=C apt-key list | grep expired

Which outputs something like this: pub 1024D/5072E1F5 2003-02-03 [expired: 2019-02-17] 5072E1F5 is the key ID, which we used in the command above.

Another one-liner that's recommended in the bug report below is this one:

sudo apt-key adv --recv-keys --keyserver pgp.mit.edu 5072E1F5

But I couldn't get it to work.

More reading from when this happened the last time.

https://bugs.mysql.com/bug.php?id=85029

0

This issue has been raised to MySQL already Bug#94378.

Workaround which helped me on Ubuntu 16.04, installed latest Ubuntu / Debian (Architecture Independent), DEB Package mysql-apt-config_0.8.12-1_all.deb

You can try this workaround.

Your Answer

By clicking "Post Your Answer", you agree to our terms of service, privacy policy and cookie policy

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