Unable to locate package、404 Not Found [IP: 185.125.190.39 80]的解决办法

文章讲述了用户在使用ubuntu21.04遇到404错误,尝试更换源和执行apt-getupdate失败。解决方案是升级至LTS版本(如20.04),因为非LTS版本不再受官方维护,官方源已停止支持。

目录

1. 简要

2. 问题背景

3. 问题解析

4. 解决途径

5. 问题总结


1. 简要

        卸载不维护的ubuntu21.04,重装 ubuntu LTS 版本(如20.04.4)即可解决。 网上说的更换源、执行sudo apt-get update都不能解决。

2. 问题背景

       做项目时文档要求ubuntu21.04版本,按照文档要求换了相应的ubuntu版本,换源也按照要求来,但是每次 apt-get update 的时候,还是失败,提示404 Not Found [IP: 185.125.190.39 80]。 

xxx@xxx:~$ sudo bash -c 'echo "deb http://mirrors.ustc.edu.cn/ubuntu-old-releases/ubuntu/ hirsute main restricted universe multiverse" > /etc/apt/source.list'
xxx@xxx:~$ sudo apt-get update
Ign:1 http://cn.archive.ubuntu.com/ubuntu hirsute InRelease
Ign:2 http://cn.archive.ubuntu.com/ubuntu hirsute-updates InRelease
Ign:3 http://security.ubuntu.com/ubuntu hirsute-security InRelease
Ign:4 http://cn.archive.ubuntu.com/ubuntu hirsute-backports InRelease
Err:5 http://security.ubuntu.com/ubuntu hirsute-security Release
  404  Not Found [IP: 185.125.190.39 80]
Err:6 http://cn.archive.ubuntu.com/ubuntu hirsute Release
  404  Not Found [IP: 91.189.91.38 80]
Err:7 http://cn.archive.ubuntu.com/ubuntu hirsute-updates Release
  404  Not Found [IP: 91.189.91.38 80]
Err:8 http://cn.archive.ubuntu.com/ubuntu hirsute-backports Release
  404  Not Found [IP: 91.189.91.38 80]
Reading package lists... Done
E: The repository 'http://security.ubuntu.com/ubuntu hirsute-security Release' no longer has 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://cn.archive.ubuntu.com/ubuntu hirsute Release' does not 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://cn.archive.ubuntu.com/ubuntu hirsute-updates Release' does not 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://cn.archive.ubuntu.com/ubuntu hirsute-backports Release' does not 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.

3. 问题解析

      ubuntu21.04版本是中间过渡版本,官方已经不维护。

4. 解决途径

1. 原来的ubuntu 21.04、21.10都不行,即只要是奇数版本的都不行,先后找了官网的源,华中科技大学的源和中科大的源,全都失败。 

2.重装20.04 LTS,执行sudo apt-get update,成功。 

5. 问题总结

      关于ubuntu的中间版本,所谓民间的源也只是官方的镜像,官方不维护则这些镜像源也没有用,我就像个冤大头摸索了三个小时。

       LTS是long term support的简称,意思是长期支持,也就是服务支持会不停更新,一般是偶数年发布,也就是18.04(这个也快要不支持了,所以不推荐现在安装这个版本),20.04和最新的22.04这些版本。

本文转自:【ubuntu21.04问题】关于404 Not Found [IP: 185.125.190.39 80]的解决办法 (yii666.com)

评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值