Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
How do I fix the GPG error “NO_PUBKEY”?

I am using 10.04 LTS - the Lucid Lynx, I shutdown the computer while one software updates running. Then after i restart my computer and when the updates manager is running, the following error occurs.

Could not download all repository indexes

The repository may no longer be available or could not be contacted because of network problems. If available an older version of the failed index will be used. Otherwise the repository will be ignored. Check your network connection and ensure the repository address in the preferences is correct.

GPG error: ./ Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520Failed to fetch 404 Not Found

I gone through the link How do I fix the GPG error “NO_PUBKEY”? and I ran the following command

sudo launchpad-getkeys 
Please wait... launchpad-getkeys is running an update so it can detect the missing GPG keys
Trying to import all the missing keys
gpg: requesting key 0F1B0520 from hkp server
gpgkeys: key C927EBE00F1B0520 not found on keyserver
gpg: no valid OpenPGP data found.
gpg: Total number processed: 0
launchpad-getkeys has finished importing all missing GPG keys. 
Try running sudo apt-get update - you shouldn't see any key 
errors anymore

But when I run sudo apt-get update again, it again shows that the key was not found on the keyserver. How to solve this problem?

share|improve this question

marked as duplicate by James Feb 23 '12 at 14:00

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

There are two errors in your question, one of them producing the GPG error.

GPG error: ./ Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520

This GPG error is not related to Launchpad and as a result the keys cannot be retrieved with launchpad-getkeys. Following the instructions on, you have to add the key with:

wget -q -O - | apt-key add -

Be aware that external repositories may be unsafe, only add repositories and keys that you really trust.

Failed to fetch**DISTRIBUTION**/main/binary-i386/Packages.gz 404 Not Found

You've made a mistake in following instructions. Edit /etc/apt/sources.list and replace **DISTRIBUTION** by your actual distribution in lowercase (e.g. oneiric). A command to do this automated:

sudo sed -i /etc/apt/sources.list "s/\*\*DISTRIBUTION\*\*/$(lsb_release -sc)/"
share|improve this answer

In the sources.list file replace DISTRIBUTION with the actual name of the distribution(ie. In this case lucid)

share|improve this answer
Try this solution and let me know if it works </> – Amith KK Jan 14 '12 at 8:14

Have you try this:

sudo rm -r /var/lib/apt/lists
sudo mkdir -p /var/lib/apt/lists/partial
sudo aptitude update

The more elaborated & updated code for ubuntu w/o aptitude is:

sudo -i  
apt-get clean  
cd /var/lib/apt  
mv lists lists.old  
mkdir -p lists/partial  
apt-get clean  
apt-get update

The solution works for the heroku tooolbelt GPG key error Courtesy:

share|improve this answer
It shows following output, Fetched 13.4MB in 4min 26s (50.3kB/s) Reading package lists... Done W: GPG error: ./ Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C927EBE00F1B0520 W: Duplicate sources.list entry ./ Packages (/var/lib/apt/lists/toolbelt.herokuapp.com_ubuntu_._Packages) W: Duplicate sources.list entry ./ Packages (/var/lib/apt/lists/toolbelt.herokuapp.com_ubuntu_._Packages) Current status: 28973 new [+28962]. – Ashok KS Oct 19 '11 at 10:37
Try to do curl | apt-key add - apt-get update – PhoneixS Nov 7 '11 at 12:58
I got the following output when the command run % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 102 1737 102 1737 0 0 353 0 0:00:04 0:00:04 --:--:-- 476 gpg: no writable keyring found: eof gpg: error reading -': general error gpg: import from -' failed: general error – Ashok KS Nov 8 '11 at 7:00
Try to do it manually, download file, go where you download the file, for example, cd /home/user/downloads/ and then apt-key add release.key and finally apt-get update. – PhoneixS Nov 23 '11 at 12:51

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