0

I'm using Ubuntu 12.04 LTS 64 bit on a Pacard Bell dot S netbook with intel atom 64 bit processor.

I get then following message when using either apt-get update or upgrade. Upgrade stops on this but update carries out the updates then reports the error

W: Duplicate sources.list entry http://archive.canonical.com/ubuntu/ precise/partner amd64 Packages (/var/lib/apt/lists/archive.canonical.com_ubuntu_dists_precise_partner_binary-amd64_Packages)

W: Duplicate sources.list entry http://archive.canonical.com/ubuntu/ precise/partner i386 Packages (/var/lib/apt/lists/archive.canonical.com_ubuntu_dists_precise_partner_binary-i386_Packages)

W: You may want to run apt-get update to correct these problems

If I remove the files when I run upgrade or update they recur.

2
  • When you say remove these files do you mean remove from your sources list? Have you update your sources list at any stage through the terminal?
    – CoalaWeb
    Apr 19, 2013 at 14:39
  • I removed them from /var/lib/apt/lists using rm <filename>
    – Fredca
    Apr 19, 2013 at 14:41

2 Answers 2

3

Basically, this means that in your /etc/apt/sources.list, you have the same repository listed twice.

This isn't exactly an error, it's a warning, and it is pretty harmless one too.

However, if you wish to stop these warnings appearing, read below, understand, then decide what you feel is best. If you don't feel comfortable with either, then don't do this. The messages you get are a warning, and isn't even remotely harmful to your OS.

First things first: Back up your /etc/apt/sources.list file in case you make a mistake. Open up a terminal, and run:

sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup_warning

(I tend to add descriptive titles to my backups instead of numbering them in case I need to go back to them later)

Now you have two ways to fix this

The simple way: Open up the Ubuntu Software Centre. On the Menu bar, click on Edit and go all the way down to Software Sources.

Click on the Other Sources tab and maximise the window to prevent removing the wrong repository. Go through the list until you find the repositories listed above and then untick. Then press close and allow the Ubuntu Software Centre to refresh packages.

If you have done this right, you should have no more warnings.

The mildly complicated way: Open up the terminal. Type

sudo gedit /etc/apt/sources.list

and then find those URLS listed above and place a hash ('#') symbol before the lines. Again, if you have done this right, you should have no more warnings.

Personally, I'd recommend you go down the simple way, as there is less chance of shooting yourself in the foot and damaging your repository updating mechanism. Or failing that, don't make a single change. Your system is absolutely fine the way it is.

2
  • There are only 4 checed sources, Canonical Partners, Independant, Independant (source code) and Canonical Partners added by software-center The reason I tried fixing it is because upgrade didn't upgrade to 12.10 whic I'm using on my desktop and would prefer to keep them the same
    – Fredca
    Apr 19, 2013 at 15:58
  • Can you elaborate on upgraded didn't upgrade. Did it partially upgrade? You may want to run apt-get clean
    – CoalaWeb
    Apr 19, 2013 at 18:15
0

You currently have both the 32bit and 64bit repositories listed in your sources list you could edit this through the terminal with the following command and then in your case remove the 32bit repository "i386".

sudo nano /etc/apt/sources.list

Or the graphical way to do this would be to open up your "Ubuntu Software Centre" then from the top menu select Edit/Software Sources...

Ubuntu Software Centre Menu

Then select the Other Software tab from the top and scroll down until you find the repository you wish to remove click it once to select it and then click Remove from the bottom menu and that’s it.

Remove from sources list

2
  • the only occurrence in /etc/apt/sources.list is commented out and it doesn't appear in the graphical tool
    – Fredca
    Apr 19, 2013 at 15:48
  • If it is commented out then yeah it wont display in the graphical list.
    – CoalaWeb
    Apr 19, 2013 at 18:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .