linux Linode| Ubuntu| sudo apt-get更新|镜像404错误

ua4mk5z4  于 11个月前  发布在  Linux
关注(0)|答案(3)|浏览(128)

在Linode(Ubuntu 16.10)上,通过以下方式启用UFW防火墙后,

sudo ufw allow OpenSSH
sudo ufw enable
sudo ufw allow in "Apache Full"

字符串
(虽然我不完全确定防火墙设置是我的问题的根源.)
sudo apt-get update给了我以下信息:

Ign:1 http://mirrors.linode.com/ubuntu yakkety InRelease
Ign:2 http://mirrors.linode.com/ubuntu yakkety-updates InRelease
Ign:3 http://mirrors.linode.com/ubuntu yakkety-backports InRelease
Err:4 http://mirrors.linode.com/ubuntu yakkety Release
  404  Not Found [IP: ****:****:*::****:**** 80]
Err:5 http://mirrors.linode.com/ubuntu yakkety-updates Release
  404  Not Found [IP: ****:****:*::****:**** 80]
Err:6 http://mirrors.linode.com/ubuntu yakkety-backports Release
  404  Not Found [IP: ****:****:*::****:**** 80]
Ign:7 http://security.ubuntu.com/ubuntu yakkety-security InRelease
Err:8 http://security.ubuntu.com/ubuntu yakkety-security Release
  404  Not Found [IP: ****:***:****::** 80]
Reading package lists... Done
E: The repository 'http://mirrors.linode.com/ubuntu yakkety Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://mirrors.linode.com/ubuntu yakkety-updates Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://mirrors.linode.com/ubuntu yakkety-backports Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://security.ubuntu.com/ubuntu yakkety-security Release' does no longer have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.


源文件/etc/apt/source.list

# deb http://mirrors.linode.com/ubuntu/ yakkety main restricted

# deb http://mirrors.linode.com/ubuntu/ yakkety-updates main restricted
# deb http://security.ubuntu.com/ubuntu yakkety-security main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://mirrors.linode.com/ubuntu/ yakkety main restricted
# deb-src http://mirrors.linode.com/ubuntu/ yakkety main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://mirrors.linode.com/ubuntu/ yakkety-updates main restricted
# deb-src http://mirrors.linode.com/ubuntu/ yakkety-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://mirrors.linode.com/ubuntu/ yakkety universe
# deb-src http://mirrors.linode.com/ubuntu/ yakkety universe
deb http://mirrors.linode.com/ubuntu/ yakkety-updates universe
# deb-src http://mirrors.linode.com/ubuntu/ yakkety-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://mirrors.linode.com/ubuntu/ yakkety multiverse
# deb-src http://mirrors.linode.com/ubuntu/ yakkety multiverse
deb http://mirrors.linode.com/ubuntu/ yakkety-updates multiverse
# deb-src http://mirrors.linode.com/ubuntu/ yakkety-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://mirrors.linode.com/ubuntu/ yakkety-backports main restricted universe multiverse
# deb-src http://mirrors.linode.com/ubuntu/ yakkety-backports main restricted universe 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 yakkety partner
# deb-src http://archive.canonical.com/ubuntu yakkety partner

deb http://security.ubuntu.com/ubuntu yakkety-security main restricted
# deb-src http://security.ubuntu.com/ubuntu yakkety-security main restricted
deb http://security.ubuntu.com/ubuntu yakkety-security universe
# deb-src http://security.ubuntu.com/ubuntu yakkety-security universe
deb http://security.ubuntu.com/ubuntu yakkety-security multiverse
# deb-src http://security.ubuntu.com/ubuntu yakkety-security multiverse


我试过sudo apt-get dist-update没有用(也给出404错误)。
我还做了unset http_proxyunset https_proxy;
apt-get -o Acquire::ForceIPv4=true update-使用IPv4时仍然失败
我可以ping 8.8.8.8很好。
......什么都不管用。有人知道怎么修吗?

e4yzc0pl

e4yzc0pl1#

Linode支持:
看起来你正在使用的Ubuntu版本已经达到了生命周期结束的状态。
https://wiki.ubuntu.com/Releases
你可以参考下面的链接,看看你是否可以用另一种方式来更新它。另一种选择是为你的服务器部署一个更新的Ubuntu映像,并将你的数据复制到新的磁盘上。
https://help.ubuntu.com/community/EOLUpgrade

umuewwlo

umuewwlo2#

我也被困在这上面了。但我让它工作了。
我不得不将/etc/apt/sources.list中的“us.archive.ubuntu.com“和“security.ubuntu.com“替换为“ old-releases.ubuntu.com“,然后我就能够完成下载一些软件包,就像Ayush Kumar在Ubuntu 17.04上的sudo apt-get update fail中所说的那样。
对于我的托管公司Linode列出的其他更新,我使用了以下内容:
我不得不在sudo apt-get update中使用--allow-unauthenticated标志。
sudo apt-get update --allow-unauthenticated
然后我就可以完成更新了。

ki1q1bka

ki1q1bka3#

这个问题已经让我抓狂了好几天,最终解决了这个问题,完全卸载ufw,清理所有剩余的资源,然后用同样的端口规则重新安装。
首先禁用ufw:

sudo ufw disable

字符串
移除 Package :

sudo apt-get remove ufw


删除以前的ufw配置文件:

sudo apt-get purge ufw


删除不常用的包并清理本地仓库:

sudo apt-get autoremove
sudo apt-get clean


重新安装ufw并根据您的喜好重新设置规则:

sudo apt install ufw


我不知道是什么原因导致初始安装和设置打破,没有改变任何东西在所有..奇怪。

相关问题