do-release-grade 无法验证

do-release-grade 无法验证

我该如何修复这个错误?

st@ThinkPad-T450s:~/Downloads$ sudo do-release-upgrade -d
Checking for a new Ubuntu release
Get:1 Upgrade tool signature [836 B]                                                     
Get:2 Upgrade tool [1.264 kB]                                                            
Fetched 1.264 kB in 0s (0 B/s)                                                           
authenticate 'zesty.tar.gz' against 'zesty.tar.gz.gpg' 
Authentication failed
Authenticating the upgrade failed. There may be a problem with the network or with the server.

我遇到了同样的错误update-manager -d

我知道我可以在 apt-get 中关闭 gpg 身份验证,但不能在 do-release-upgrade 或 update-manager 中关闭

答案1

您可以尝试从 /etc/apt 目录中删除受信任的密钥。

rm -rf /etc/apt/trusted*

此后,您必须更新您的软件包列表:

apt-get update

您将看到一些缺少密钥的错误。现在,您可以重新导入密钥:

apt-key adv --keyserver http://keyserver.ubuntu.com:80 --recv-keys KEY_ID

此后do-release-upgrade就可以正常工作。

相关内容