1

When I run the command: root@versinator:~# apt-get update I get the following error:

Hit:1 http://us-east1.gce.archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://us-east1.gce.archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:3 http://us-east1.gce.archive.ubuntu.com/ubuntu bionic-backports InRelease
Hit:4 http://archive.canonical.com/ubuntu bionic InRelease
Hit:6 http://security.ubuntu.com/ubuntu bionic-security InRelease
Hit:7 http://ppa.launchpad.net/webupd8team/y-ppa-manager/ubuntu bionic InRelease
Get:5 http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease [17.5 kB]
Err:5 http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 1E9377A2BA9EF27F
Reading package lists... Done
W: GPG error: http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 1E9377A2BA9EF27F
E: The repository 'http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

How can I remove this error and get back to the secured state?

aviral sanjay
  • 111
  • 1
  • 4

3 Answers3

2

The issue of "apt-get update" is that you are missing the public key 1E9377A2BA9EF27F. You can add this key to your keyring through executing:

sudo apt-key adv --recv-key 1E9377A2BA9EF27F

It will show you something like:

Executing: /tmp/apt-key-gpghome.IA65nrxcnz/gpg.1.sh --recv-key 1E9377A2BA9EF27F
gpg: key 1E9377A2BA9EF27F: public key "Launchpad Toolchain builds" imported
gpg: Total number processed: 1
gpg:               imported: 1

Now you can run "apt-get update", or "apt update" and it will fetch the index of "http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial InRelease" as well.

0

Edit the file :

sudo nano /etc/apt/sources.list

Put a # as the first character on the line.

Then, simply do an update:

sudo apt update

If the errors disappear, you can remove the remarked lines.

MatsK
  • 916
0

Go to synaptic then settings tab repositories then other software. uncheck the box in front of the ppa for Ubuntu-toolchain-r. the reload.

kc1di
  • 382