sudo apt get update出现问题:仓库cdrom...没有Release文件。

每次我尝试更新我的Ubuntu(使用sudo apt-get update),都会遇到这个问题:
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
你可以通过在“系统设置 > 软件和更新”中取消选中 CD-ROM 源来解决与光驱相关的错误。 - Mostafa Ahangarha
2个回答

要解决这个问题,你必须从终端直接删除/注释掉/etc/apt/sources.list中的CD-ROM存储库源。
 sudo nano /etc/apt/sources.list

并评论或删除包含cdrom的行。例如:

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

6这应该是被接受的答案。它适用于桌面和服务器发行版。 - mau
解决了我的问题!但是有没有人能告诉我除了光盘驱动器之外,还会受到影响吗?我们被建议评论的东西?(在VMware中的虚拟机内工作) - Asif Mehmood
1它不会影响其他任何东西,只能将光盘作为软件包的来源。 - PRIHLOP
试图澄清一下,我认为这是有区别的。如果你实际上不想使用CD-ROM进行更新(我甚至没有一个),那么这似乎是适合你或像mauMalik Asif和我这样的人的答案。你可能还想考虑一下这个问题和回答:https://askubuntu.com/q/42441/830570 - Cadoiz

试试这个: 打开“软件和更新”,在“Ubuntu软件”选项卡中取消选中“可从CD-ROM/DVD安装”的部分下的“带有Ubuntu 16.04 LTS 'Xenial Xerus'的Cdrom”。

对我来说起作用。我正在使用14.04版本。这是怎么进入软件源的呢?我唯一能想象的可能是因为我用启动盘创建器制作了一个16.04版本的USB启动盘。 - atmelino
对我来说是同样的原因 - Alexey
在PureOS上遇到了这个问题,通过"软件和更新"解决了,就像你的回答中所说的那样,还有一些补充:在"PureOS软件"选项卡中,找到"可从互联网下载",勾选"官方支持(主要)",然后在"其他软件"选项卡中取消勾选"光盘"。 - Ida
@atmelino:是的,这是在使用USB闪存安装后发生的。看起来有一个关于此问题的错误报告,但已经关闭了:https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=807996 - Ida
这是我遇到并搜索到的错误信息之一:E: 仓库 'cdrom://[Debian GNU/Linux none Green - Official Snapshot amd64 LIVE/INSTALL Binary 20180120-02:05] green Release' 没有 Release 文件。 - Ida