所以我回答了这个问题如何修复重复的 sources.list 条目?并且大部分内容都是答案,但这个问题似乎没有得到解决。我得到的错误是:
Fetched 30.0 MB in 51s (577 kB/s)
Reading package lists... Done
W: Duplicate sources.list entry http://archive.ubuntu.com/ubuntu/ trusty-backports/multiverse amd64 Packages (/var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_trusty-backports_multiverse_binary-amd64_Packages)
W: Duplicate sources.list entry http://archive.ubuntu.com/ubuntu/ trusty-backports/multiverse i386 Packages (/var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_trusty-backports_multiverse_binary-i386_Packages)
W: You may want to run apt-get update to correct these problems
这source.list
:
# deb cdrom:[Ubuntu 13.10 _Saucy Salamander_ - Release amd64 (20131016.1)]/ saucy main restricted
# deb cdrom:[Ubuntu 13.04 _Raring Ringtail_ - Release amd64 (20130424)]/ raring main restricted
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://archive.ubuntu.com/ubuntu trusty main restricted
deb-src http://archive.ubuntu.com/ubuntu trusty main restricted
## Major bug fix updates produced after the final release of the
## distribution.
deb http://archive.ubuntu.com/ubuntu trusty-updates main restricted
deb-src http://archive.ubuntu.com/ubuntu trusty-updates main restricted
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://archive.ubuntu.com/ubuntu trusty universe
deb-src http://archive.ubuntu.com/ubuntu trusty universe
deb http://archive.ubuntu.com/ubuntu trusty-updates universe
deb-src http://archive.ubuntu.com/ubuntu trusty-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://archive.ubuntu.com/ubuntu trusty multiverse
deb-src http://archive.ubuntu.com/ubuntu trusty multiverse
deb http://archive.ubuntu.com/ubuntu trusty-updates multiverse
deb-src http://archive.ubuntu.com/ubuntu trusty-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu trusty-security main restricted
deb-src http://archive.ubuntu.com/ubuntu trusty-security main restricted
deb http://archive.ubuntu.com/ubuntu trusty-security universe
deb-src http://archive.ubuntu.com/ubuntu trusty-security universe
deb http://archive.ubuntu.com/ubuntu trusty-security multiverse
deb-src http://archive.ubuntu.com/ubuntu trusty-security multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
deb http://archive.canonical.com/ubuntu raring partner
deb-src http://archive.canonical.com/ubuntu raring partner
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
deb http://extras.ubuntu.com/ubuntu trusty main
deb-src http://extras.ubuntu.com/ubuntu trusty main
# deb http://deb.torproject.org/torproject.org trusty main # disabled on upgrade to trusty
deb http://archive.ubuntu.com/ubuntu trusty-backports multiverse
deb-src http://archive.ubuntu.com/ubuntu trusty-backports multiverse
我尝试过的是
- 删除 source.list 文件
- sudo mv /etc/apt/sources.list.d /etc/apt/sources.list.d.bak
- sudo rm /etc/apt/sources.list.distUpgrade
- 删除其中一个重复的源存储库,并确保没有其他
我使用的命令是sudo apt-get clean && sudo apt-get update
。甚至尝试过不使用清理命令。
我该如何解决这个问题?
背景:
- 我的 Emacs Tramp 出现错误
cond: Couldn't find a proper `ls' command
。所以我尝试了以下答案这里。但是沒有結果。 尝试编译 Emacs 24.4(软件中心不可用)。无法编译,因为(
sudo apt-get build-dep emacs24
):The following packages have unmet dependencies: libgtk-3-dev : Depends: libgtk-3-0 (= 3.10.8-0ubuntu1.2) but 3.12.2-0ubuntu4~trusty1 is to be installed E: Build-dependencies for emacs24 could not be satisfied.
- 然后我发现这. 修复损坏的软件包使用命令
sudo apt-get clean && sudo apt-get update
答案1
我无法评论,所以我必须将其添加为答案。
你能展示一下你的 sources.list 吗?
我不认为问题出在 sources.list.d/*.list 上,因为错误出在 ubuntu multiverse repo 上。我敢打赌你的/etc/apt/sources.list
系统中有两个 trusty-backports multiverse 条目。它可能是一行重复,或者类似
deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu trusty-backports multiverse
在文本编辑器中打开sources.list
,找到重复项并删除多余的行。