我将此密钥添加到我的系统中:
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
但我不喜欢它,并尝试手动删除它,但实际上做错了,所以NO_PUB_KEY...
运行后出现 GPG 密钥错误apt-get update
。我得到了一大堆公钥,所以:
我跑了:
apt-key list | grep google*
但它只显示谷歌,uid
但没有pub
,我需要pub
运行apt-key del
。
那么我需要在这个命令行中添加/编辑什么apt-key list | grep google*
才能让它搜索 Google pub
?
答案1
打开终端并输入
apt-key list
它将列出您添加的所有密钥及其公钥 ID。我已尝试过您的方法,我看到了 Google pub ID
abcdefgg@abcdefgg-virtual-machine:~$ wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
[sudo] password for abcdefgg:
OK
abcdefgg@abcdefgg-virtual-machine:~$ sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
abcdefgg@abcdefgg-virtual-machine:~$ apt-key list | grep google*
uid Google, Inc. Linux Package Signing Key <[email protected]>
abcdefgg@abcdefgg-virtual-machine:~$ apt-key list
/etc/apt/trusted.gpg
--------------------
pub 1024D/437D05B5 2004-09-12
uid Ubuntu Archive Automatic Signing Key <[email protected]>
sub 2048g/79164387 2004-09-12
pub 1024D/FBB75451 2004-12-30
uid Ubuntu CD Image Automatic Signing Key <[email protected]>
pub 4096R/C0B21F32 2012-05-11
uid Ubuntu Archive Automatic Signing Key (2012) <[email protected]>
pub 4096R/EFE21092 2012-05-11
uid Ubuntu CD Image Automatic Signing Key (2012) <[email protected]>
pub 1024D/3E5C1192 2010-09-20
uid Ubuntu Extras Archive Automatic Signing Key <[email protected]>
pub 1024D/7FAC5991 2007-03-08
uid Google, Inc. Linux Package Signing Key <[email protected]>
sub 2048g/C07CB649 2007-03-08
abcdefgg@abcdefgg-virtual-machine:~$