无法在 Debian Stable 中安装最新的 R 统计包

无法在 Debian Stable 中安装最新的 R 统计包

我正在尝试按照本页上的说明在 Debian Stable (Buster) 上安装最新的 R 软件包:https://cloud.r-project.org/

我将以下内容添加到/etc/apt/sources.list:

deb https://cran.csiro.au/bin/linux/debian buster-cran35/

但是,当我运行时sudo apt-get update,出现以下错误:

$ sudo apt-get update
Hit:1 http://deb.debian.org/debian buster InRelease                   
Hit:2 http://deb.debian.org/debian-security buster/updates InRelease  
Hit:3 http://deb.debian.org/debian buster-updates InRelease          
Hit:4 http://deb.debian.org/debian buster-backports InRelease        
Get:5 https://cran.csiro.au/bin/linux/debian buster-cran35/ InRelease [4,375 B]
Err:5 https://cran.csiro.au/bin/linux/debian buster-cran35/ InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY FCAE2A0E115C3D8A
Reading package lists... Done
W: GPG error: https://cran.csiro.au/bin/linux/debian buster-cran35/ InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY FCAE2A0E115C3D8A
E: The repository 'https://cran.csiro.au/bin/linux/debian buster-cran35/ InRelease' 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.

尽管进行了以下尝试,我仍无法摆脱此 GPG 错误:

sudo apt-get install debian-keyring

sudo launchpad-getkeys

sudo aptitude install debian-archive-keyring

我该如何解决这个错误?

答案1

你需要导入存档密钥,使用错误消息中给出的 id(假设您信任存储库):

apt-key adv --keyserver keys.gnupg.net --recv-key FCAE2A0E115C3D8A

相关内容