解决E: 仓库 “https://download.docker.com/linux/ubuntu focal Release” 不再含有 Release 文件

运行sudo apt-get update时报错

获取:1 file:/var/cudnn-local-repo-ubuntu2004-8.9.7.29 InRelease [1,572 B]
获取:1 file:/var/cudnn-local-repo-ubuntu2004-8.9.7.29 InRelease [1,572 B]
命中:2 https://mirrors.ustc.edu.cn/ubuntu focal InRelease
命中:4 https://mirrors.ustc.edu.cn/ubuntu focal-security InRelease
忽略:5 https://download.docker.com/linux/ubuntu focal InRelease
命中:6 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal InRelease
命中:7 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-updates InRelease
获取:8 https://dl.google.com/linux/chrome/deb stable InRelease [1,825 B]
命中:9 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-backports InRelease
错误:10 https://download.docker.com/linux/ubuntu focal Release
Could not handshake: Error in the pull function. [IP: 2600:9000:23d2:a200:3:db06:4200:93a1 443]
命中:11 https://mirrors.tuna.tsinghua.edu.cn/ubuntu focal-security InRelease
错误:8 https://dl.google.com/linux/chrome/deb stable InRelease
由于没有公钥,无法验证下列签名: NO_PUBKEY E88979FB9B30ACF2
命中:12 http://security.ubuntu.com/ubuntu focal-security InRelease
命中:3 https://packages.microsoft.com/repos/code stable InRelease 忽略:13 https://deepin-wine.i-m.dev InRelease
命中:14 https://deepin-wine.i-m.dev Release
忽略:15 https://deepin-wine.i-m.dev Release.gpg
正在读取软件包列表… 完成
E: 仓库 “https://download.docker.com/linux/ubuntu focal Release” 不再含有 Release 文件。
N: 无法安全地用该源进行更新,所以默认禁用该源。
N: 参见 apt-secure(8) 手册以了解仓库创建和用户配置方面的细节。
W: 校验数字签名时出错。此仓库未被更新,所以仍然使用此前的索引文件。GPG 错误:https://dl.google.com/linux/chrome/deb stable InRelease: 由于没有公钥,无法验证下列签名: NO_PUBKEY E88979FB9B30ACF2

方法一:更新Ca-certificates(亲测有效)

到官网 Ca-certificates Download for Linux (apk, deb, ipk, rpm, tgz, txz, xbps, xz, zst)找到对应版本的Ca-certificates,例如我的是

外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传

点进详情,用wget下载包并安装。

在这里插入图片描述

wget http://ports.ubuntu.com/pool/main/c/ca-certificates/ca-certificates_20240203~20.04.1_all.deb
sudo dpkg -i ca-certificates_20240203~20.04.1_all.deb

再次运行

sudo apt-get update

之后只剩一些warning了

方法二:删除错误文件

cd /etc/apt/sources.list.d
sudo rm <报错的源名称对应的文件名>.list

参考链接:

Ubuntu系统update时提示源不安全被禁用

更新ubuntu源时出现的问题

评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值