GPG error when updating Linux Mint 9

4

1

When i run sudo apt-get update, i get the following error

W: GPG error: http://ppa.launchpad.net lucid Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 9BDB3D89CE49EC21.

I tried searching for it, but wasn't able to find anything helpful. What is the reason for this, and how can i fix this?

Edit1: I am using Linux mint 9.

Edit2: On sudo add-apt-repository ppa:mozillateam/firefox-stable/ubuntu, I was getting gpgkeys: HTTP fetch error 7: couldn't connect to host, so i did according to this post. When I run sudo apt-get update, it gives no errors. But, firefox 5 is still not installed. In my update manager when I try to install, it says "Fix broken packages first". In Synaptic manager there is an option of "Fix broken Packages", but it does nothing. What is going wrong here?

Edit3: Update is used to resynchronize the package index files from their sources, and Upgrade is used to install latest versions. So, I was forgetting about upgrade!

Thanks!

Priyank Bhatnagar

Posted 2011-07-01T12:42:38.277

Reputation: 143

This occurs today, with Linux Mint 17.2 . – K7AAY – 2015-09-24T02:26:29.553

try this: apt-get --fix-broken – Sunny – 2011-07-01T15:23:18.453

@Sunny : --fix-broken is to be used with one command, right? I used it as apt-get --fix-broken update, still firefox is not updated. – Priyank Bhatnagar – 2011-07-01T16:33:06.020

Answers

2

Edit your /etc/apt/sources.list, and comment out the offending line (add "#" at the beginning of the line). The line you are looking for should have "ppa" in it. Save the file. Pls - note which ppa was mentioned there.

If in sources.list there is no ppa mentioned, check the files in /etc/apt/sources.list.d/ for a file which has "ppa" mentioned in there". Move this file to somewhere (so you have backup).

Then do:

sudo add-apt-repository ppa:any-ppa-that-I-need

This will add the ppa back to sources, but will fetch and install the pgp key as well.

Sunny

Posted 2011-07-01T12:42:38.277

Reputation: 921

Fails in Linux Cinnamon Mint 17.2 64-bit with

Cannot add PPA: 'No JSON object could be decoded'.

– K7AAY – 2015-09-24T01:00:43.220

How to know which ppa to add? Currently in my sources.list file there is no ppa. But in the directory sources.list.d there is mozillateam-firefox-stable-lucid.list which has ppa in it. – Priyank Bhatnagar – 2011-07-01T13:34:49.263

then just move this file out (so you have backup): mv mozillateam-firefox-stable-lucid.list ~, then add the repo again. (see the exact ppa name in that file). – Sunny – 2011-07-01T13:44:11.213

Please take a look at my edit2. – Priyank Bhatnagar – 2011-07-01T15:15:40.003

Thanks! With your method, I was able to update my system. – Priyank Bhatnagar – 2011-07-01T17:03:00.113

2

The most direct method is to use apt itself:

$ apt-key update


The Ubuntu Forums have a couple things to say about this using more roundabout methods, if apt doesn't do it properly.

ok. I figured it out.

do this:

wget http://packages.freecontrib.org/ubuntu/plf/12B83718.gpg

and then open up synaptic and go to settings>repos>authentication and "import file key" browse the key and click ok.

and then sudo aptitude update


And this:

sudo wget http://ftp-master.debian.org/ziyi_key_2006.asc -O - | sudo apt-key add -


This is the link to my Google search - there's quite a bit much there to put in a single response.

new123456

Posted 2011-07-01T12:42:38.277

Reputation: 3 707

apt-key update does nothing. The second link that you gave, when I run wget, I get ERROR 503: Service Unavailable. and the last link that you gave, on wget I get 404 Not Found. – Priyank Bhatnagar – 2011-07-01T13:06:21.017

Please take a look at edit2. – Priyank Bhatnagar – 2011-07-01T15:16:29.300

1

Thanks to ChrisJean.com I fixed this entirely in about 10 minutes.

First, collect a list of the GPG errors, by
cd /etc/apt/sources/list/d
sudo apt-get update > listoferrors

Do sudo nano listoferrors and strip out everything but the 16 character hexadecimal strings, and a space between each, then add at the beginning
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys so the hex strings, with a space between each, follow that apt-key command.

Copy the entire string and paste it into a terminal window with Ctrl-Shift-V. You end up with something like
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 0123456789ABCDEF FEDCBA9876543210 11A11B11C11D11E1

Run it. It goes out, retrieves the correct keys, and puts them in place.

Then, another sudo apt-get update runs without flaw.

Close and delete the listoferrors file.

K7AAY

Posted 2011-07-01T12:42:38.277

Reputation: 6 962