ubuntu 换源

sudo apt update

错误如下

复制代码
Ign:1 http://security.ubuntu.com/ubuntu focal-security InRelease
Ign:2 http://us.archive.ubuntu.com/ubuntu focal InRelease          
Err:3 http://security.ubuntu.com/ubuntu focal-security Release     
  SECURITY: URL redirect target contains control characters, rejecting. [IP: 91.189.91.81 80]
Ign:4 http://us.archive.ubuntu.com/ubuntu focal-updates InRelease  
Ign:5 http://us.archive.ubuntu.com/ubuntu focal-backports InRelease
Err:6 http://us.archive.ubuntu.com/ubuntu focal Release
  SECURITY: URL redirect target contains control characters, rejecting. [IP: 91.189.91.81 80]
Err:7 http://us.archive.ubuntu.com/ubuntu focal-updates Release
  SECURITY: URL redirect target contains control characters, rejecting. [IP: 91.189.91.83 80]
Err:8 http://us.archive.ubuntu.com/ubuntu focal-backports Release
  SECURITY: URL redirect target contains control characters, rejecting. [IP: 91.189.91.83 80]
Reading package lists... Done
E: The repository 'http://security.ubuntu.com/ubuntu focal-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://us.archive.ubuntu.com/ubuntu focal 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://us.archive.ubuntu.com/ubuntu focal-updates 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://us.archive.ubuntu.com/ubuntu focal-backports 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.

--- > 换源后解决

换源方法如后面。

就换源就解决了,很简单

1,更换网络,改用手机连接

2,更换https软件软件源,比如清华的。

打开链接:https://mirror.tuna.tsinghua.edu.cn/help/ubuntu/

选择合适的ubuntu版本,更新仓库配置文件/etc/apt/sources.list。

mv /etc/apt/sources.list /etc/apt/sources.list_bak

vim /etc/apt/sources.list

refer https://blog.csdn.net/shangyexin/article/details/102657776

相关推荐
飘忽不定的bug17 小时前
ubuntu20.04交叉编译QT5.15.12(RK3562+ubuntu20.04)
linux·qt·ubuntu
库玛西17 小时前
深入浅出Linux select网络模型:从底层位图原理到C++面向对象高级封装
linux·服务器·网络·c++·ubuntu
迷路爸爸18018 小时前
在 Ubuntu / Linux 上轻量安装 LaTeX:TinyTeX 使用记录
linux·运维·ubuntu
与自己和解74118 小时前
使用ssh实现 VScode 直连 ubuntu
vscode·ubuntu·ssh
2601_9622998819 小时前
Linux下运行Python脚本
linux·python·ubuntu·脚本·命令
skywalk816319 小时前
通过下载Ubuntu ova文件在Virtual Box快速安装ubuntu
linux·运维·ubuntu·virtualbox
捷瑞电子工坊20 小时前
Ubuntu 下安装 VSCode 和 gcc 的简单步骤
vscode·ubuntu·代码编辑器·安装教程·gcc·deb·snap
YHHLAI2 天前
TypeScript 高级工具类型面试指南
ubuntu·面试·typescript
CS_Zero2 天前
Ubuntu 22.04挂载新硬盘
linux·运维·ubuntu
洪流之源2 天前
Windows 远程 Ubuntu 24.04 桌面
linux·windows·ubuntu