无法下载存储库信息 - 软件更新程序

无法下载存储库信息 - 软件更新程序

我运行的是 Ubuntu 14.04LTS,64 位。我尝试运行软件更新程序,但出现了“无法下载存储库信息。请检查您的 Internet 连接”消息 (截屏)。

在此处输入图片描述

我跑了apt-get update,它给了我这个:

Hit http://security.ubuntu.com trusty-security InRelease
Ign http://us.archive.ubuntu.com trusty InRelease
Hit http://security.ubuntu.com trusty-security/multiverse amd64 Packages
Hit http://us.archive.ubuntu.com trusty-updates InRelease         
Hit http://security.ubuntu.com trusty-security/main amd64 Packages       
Hit http://us.archive.ubuntu.com trusty-backports InRelease
Hit http://us.archive.ubuntu.com trusty Release.gpg                    
Hit http://us.archive.ubuntu.com trusty-updates/multiverse amd64 Packages
Hit http://us.archive.ubuntu.com trusty-updates/main amd64 Packages
Hit http://us.archive.ubuntu.com trusty-backports/multiverse amd64 Packages
Hit http://us.archive.ubuntu.com trusty-backports/main amd64 Packages
Hit http://us.archive.ubuntu.com trusty Release
Hit http://us.archive.ubuntu.com trusty/main Sources
Hit http://us.archive.ubuntu.com trusty/restricted Sources
Hit http://us.archive.ubuntu.com trusty/universe Sources
Hit http://us.archive.ubuntu.com trusty/multiverse Sources
Hit http://us.archive.ubuntu.com trusty/main amd64 Packages
Hit http://us.archive.ubuntu.com trusty/restricted amd64 Packages
W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease  Unable to find expected entry 'non-free/binary-amd64/Packages' in Release file (Wrong sources.list entry or malformed file)

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/InRelease  Unable to find expected entry 'non-free/binary-amd64/Packages' in Release file (Wrong sources.list entry or malformed file)

W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease  Unable to find expected entry 'non-free/binary-amd64/Packages' in Release file (Wrong sources.list entry or malformed file)

W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty/Release  Unable to find expected entry 'non-free/binary-amd64/Packages' in Release file (Wrong sources.list entry or malformed file)

E: Some index files failed to download. They have been ignored, or old ones used instead.

我尝试将镜像服务器更改为其他几个,包括“主服务器”,但结果是一样的。错误似乎来自/etc/apt/sources.list或来自/etc/apt/sources.list.d/*

这是/etc/apt/sources.list

# deb cdrom:[Ubuntu 14.04.3 LTS _Trusty Tahr_ - Beta amd64 (20150805)]/ trusty main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted non-free
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty main restricted

## Major bug fix updates produced after the final release of the
## distribution.

## 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://us.archive.ubuntu.com/ubuntu/ trusty universe
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty 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://us.archive.ubuntu.com/ubuntu/ trusty multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty 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.


## 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 trusty partner
# deb-src http://archive.canonical.com/ubuntu trusty 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://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse main non-free restricted universe
deb http://security.ubuntu.com/ubuntu/ trusty-security multiverse main non-free restricted universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-backports multiverse main non-free restricted universe

这是/etc/apt/sources.list.d/*

# deb http://ppa.launchpad.net/alex-wv/pulseaudio-equalizer-ppa/ubuntu trusty main
# deb-src http://ppa.launchpad.net/alex-wv/pulseaudio-equalizer-ppa/ubuntu trusty main
# deb http://ppa.launchpad.net/alex-wv/pulseaudio-equalizer-ppa/ubuntu trusty main
# deb-src http://ppa.launchpad.net/alex-wv/pulseaudio-equalizer-ppa/ubuntu trusty main
# deb http://ppa.launchpad.net/jfi/ppa/ubuntu trusty main
# deb-src http://ppa.launchpad.net/jfi/ppa/ubuntu trusty main
# deb http://ppa.launchpad.net/jfi/ppa/ubuntu trusty main
# deb-src http://ppa.launchpad.net/jfi/ppa/ubuntu trusty main
# deb http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb-src http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb-src http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb-src http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb-src http://ppa.launchpad.net/mystic-mirage/pycharm/ubuntu trusty main
# deb http://deb.playonlinux.com/ trusty main
# deb http://deb.playonlinux.com/ trusty main
# deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main
# deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main
# deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main
# deb-src http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main

我还取消选中了“软件和更新”程序中的所有“其他软件”框,只是想看看问题是否来自非官方数据包,但似乎不是。有什么办法可以解决这个问题吗?

答案1

在终端中使用这一行:

sudo sed -i 's/\ non-free//' /etc/apt/sources.list

这将改变以下几行/etc/apt/sources.list并删除它们,non-free使它们看起来像这样:

deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted

.
.
.

deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse main restricted universe
deb http://security.ubuntu.com/ubuntu/ trusty-security multiverse main restricted universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-backports multiverse main restricted universe

这应该可以解决你的问题。

答案2

deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse main non-free restricted universe
deb http://security.ubuntu.com/ubuntu/ trusty-security multiverse main non-free restricted universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-backports multiverse main non-free restricted universe

non-free不是 Ubuntu 组件。那是 Debian。Ubuntu 的对应项是和restricted。Ubuntumultiverse只有mainrestricted和。universemultiverse

相关内容