如何让Linux上的GPG error 无法验证的这个公钥 NO_PUBKEY D97A3AE911FXXXXX 出错信息消失?

环境:Linux Debian 10

出错信息:

W: GPG error: http://download.webmin.com/download/repository sarge Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY D97A3AE911FXXXXX
E: The repository 'http://download.webmin.com/download/repository sarge Release' is not signed.
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.

查看apt-key验证过的公钥

apt-key list

只能看到下面的出错信息
E: gnupg, gnupg2 and gnupg1 do not seem to be installed, but one of them is required for this operation

解决方法:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys D97A3AE911FXXXXX

看到下面的输出就大功告成了!
Executing: /tmp/apt-key-gpghome.K7Qsqn0eCC/gpg.1.sh --keyserver keyserver.ubuntu.com --recv-keys D97A3AE911FXXXXX
gpg: key D97A3AE911FXXXXX: 1 duplicate signature removed
gpg: key D97A3AE911FXXXXX: public key “Jamie Cameron jcameron@webmin.com” imported
gpg: Total number processed: 1
gpg: imported: 1

可以用apt-key list再验证

删除当前公钥命令:

sudo apt-key del "AC53 0D52 0F2F 3269 F5E9  8313 A484 4904 4AAD 5C5D"

这个方法可用于 Debian 和 Ubuntu

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值