sudo apt get update的问题:仓库cdrom…没有发布文件


30

每当我尝试使用(sudo apt-get update)更新Ubuntu时,都会出现此问题:

W: The repository 'cdrom://Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1) xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'ppa.launchpad.net/kirillshkrogalev/ffmpeg-next/ubuntu xenial Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Failed to fetch cdrom://Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)/dists/xenial/main/binary-amd64/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs
E: Failed to fetch cdrom://Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)/dists/xenial/main/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs
E: Failed to fetch ppa.launchpad.net/kirillshkrogalev/ffmpeg-next/ubuntu/dists/xenial/main/binary-amd64/Packages  404  Not Found
E: Failed to fetch ppa.launchpad.net/kirillshkrogalev/ffmpeg-next/ubuntu/dists/xenial/main/binary-i386/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.

我该如何解决?
我使用Ubuntu 16.04 LTS


对于ppa错误,请参阅此问题。从您发布的内容来看,我认为其他来源的更新都可以正常工作,在这种情况下,您无需担心此错误
Zanna

您可以通过在系统设置>软件和更新
Mostafa Ahangarha,2016年

Answers:


24

要从终端解决此问题,您必须直接从以下位置删除/注释此CD-ROM存储库源 /etc/apt/sources.list

 sudo nano /etc/apt/sources.list

并注释或删除包含cdrom的行。例如:

deb cdrom:[Ubuntu-Server 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.3)]/ xenial main restricted

2
这应该是公认的答案。它适用于台式机和服务器发行版。
mau

解决了我的问题!但是,有人可以说除cdrom以外的任何东西都会受到影响吗?我们建议对此发表评论。(在VMware的虚拟机中工作)
Malik Asif

1
它不会影响其他任何东西,只有cd-rom作为软件包的来源。
PRIHLOP

19

尝试以下操作:
打开“ 软件和更新”,然后在“ Ubuntu软件”选项卡中,取消选中“可从CD-ROM / DVD安装下的“具有Ubuntu 16.04 LTS'Xenial Xerus'的Cd​​rom”


为我工作。我正在使用14.04。首先,这是如何进入软件资源的?我唯一能想象的是因为我用启动盘创建程序制作了16.04 USB记忆棒。
atmelino '16

对我来说也是同样的原因
Alexey

有了PureOS的问题,可以通过“软件和更新”解决,就像您在答案中添加以下这些内容:在选项卡“ PureOS Software”中说“可从互联网下载”的复选框中,选中“官方支持(主)”,然后选中“其他”。 “软件”中取消选中“ cdrom”框。
艾达·埃布克斯

@atmelino:是的,这是从USB记忆棒安装后发生的。看起来有一个错误报告,但已经关闭了:bugs.debian.org/cgi-bin/bugreport.cgi?bug=807996
Ida Ebkes

PS:这是我得到并搜索的错误的其中一行:E:存储库“ cdrom:// [Debian GNU / Linux无绿色 -官方快照amd64 LIVE / INSTALL Binary 20180120-02:05]绿色Release”没有有一个发布文件。
艾达·埃布克斯
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.