If you use Ubuntu, you may have noticed that the default installation doesn’t include a GPG key management tool. This is because Ubuntu uses the GnuPG package from the official repositories, which includes a GPG key management tool. However, if you want to add your own GPG keys, or manage your keys more securely, there are a few different options available. The first option is to use the gpg-agent software. This is a lightweight agent that can be installed on most systems and will automatically manage your keys for you. gpg-agent can be configured to run as a background process or as a daemon, and it supports multiple authentication methods including fingerprint readers and smartcards. The second option is to use the gpg4win software. This is an open source GPG key management tool that can be used on Windows systems. It supports multiple authentication methods including fingerprint readers and smartcards, and it has features such as automatic key rotation and encrypted file storage. The final option is to use the command line tools available in Ubuntu. These tools include gpg2 and gpg3 , which are both command line tools that support multiple authentication methods including fingerprint readers and smartcards. ..


If you have missing GPG keys you’ll get an error like the one above in the screenshot if you are using Synaptic Package Manager and a similar one if you use the terminal. “Launchpad-getkeys” is a script that imports these missing keys automatically.

When adding PPAs to Ubuntu via “apt-add-repository” the PPA and its key will be imported. These GPG keys are a way to verify the packages in that PPA. But if you add a PPA when the Ubuntu key server is down the key will not be imported and the PPA will produce an error every time you try refreshing your packages. Ubuntu Forums user (blackgr) created a script called “launchpad-getkeys” that will import all missing keys automatically. To get this script on your computer, type these commands in a terminal and hit “Enter” after every line.

Launchpad-getkeys is now installed. To import keys, just run:

sudo apt-get update

sudo apt-get install launchpad-getkeys

As launchpad-getkeys says, you shouldn’t see any key errors anymore.