使用apt-get时出现 “no public key available” 的解决方法

简介: 在 Debian 和 Ubuntu 下运行 apt-get update 刷新更新源的时候,经常遇到 “There is no public key available for the following key IDs” 的问题,具体表现为以下错误提示: W:There is no publi.

在 Debian 和 Ubuntu 下运行 apt-get update 刷新更新源的时候,经常遇到 “There is no public key available for the following key IDs” 的问题,具体表现为以下错误提示:

W:There is no public key available for the following key IDs: 3B4FE6ACC0B21F32,
W:There is no public key available for the following key IDs: 3B4FE6ACC0B21F32,

解决方法如下,

sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 3B4FE6ACC0B21F32

把 3B4FE6ACC0B21F32 替换为你出现问题的IDs。另外,如果有如下问题,是因为加入了 natty-backports 源,删掉即可:

W:Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/natty-backports/main/source/Sources 404 Not Found [IP: 91.189.91.13 80],
W:Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/natty-backports/restricted/source/Sources 404 Not Found [IP: 91.189.91.13 80],
W:Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/natty-backports/universe/source/Sources 404 Not Found [IP: 91.189.91.13 80],
W:Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/natty-backports/multiverse/source/Sources 404 Not Found [IP: 91.189.91.13 80],

运行如下命令:

sudo sed -i '/natty\-backports/d' /etc/apt/sources.list{,.d/*}

原文发布时间:2017-11-07
本文来自云栖社区合作伙伴“ Debian社区”,了解相关信息可以关注“ Debian社区”。
相关文章
|
Ubuntu 开发工具
Ubuntu更换阿里云软件源
Ubuntu更换阿里云软件源
145250 0
|
Ubuntu
Ubuntu 安装使用yum
Ubuntu 安装使用yum
3427 0
解决办法:gpg : 从公钥服务器接收失败:公钥服务器错误
解决办法:gpg : 从公钥服务器接收失败:公钥服务器错误
8713 0
修改apt-get源为国内镜像源
修改apt-get源为国内镜像源
7510 0
|
网络协议 Ubuntu Linux
gpg从公钥服务器接收失败(gpg: keyserver receive failed: Server indicated a failure)
通过上述步骤,大多数情况下应该能够解决GPG从公钥服务器接收失败的问题。如果问题依旧存在,可能需要进一步调查与公钥服务器相关的更深层次的技术问题,或者考虑在相关社区论坛寻求帮助。
3434 1
|
Java 应用服务中间件 PHP
Nginx——*5 connect() failed (111: Connection refused) while connecting to upstream
Nginx——*5 connect() failed (111: Connection refused) while connecting to upstream
1660 0
Nginx——*5 connect() failed (111: Connection refused) while connecting to upstream
|
缓存 安全 网络协议
【Linux】已解决:There are no enabled repos. Run “yum repolist all” to see the repos you have. You can en
【Linux】已解决:There are no enabled repos. Run “yum repolist all” to see the repos you have. You can en
2759 1
|
机器学习/深度学习 弹性计算 Ubuntu
“炫技”还是“真硬核”,OpenPPL 实测阿里「倚天 710」芯片
本文将以「深度学习模型推理应用」为出发点,对「倚天 710」这款 ARM Server 芯片进行性能实测。
2715 0
“炫技”还是“真硬核”,OpenPPL 实测阿里「倚天 710」芯片
|
C语言 Linux
linux系统的glibc是什么?为什么很重要?
【6月更文挑战第3天】linux系统的glibc是什么?为什么很重要?
1710 2