cran4linux/bspm

error installing on ubuntu focal fossa (WSL2) repository not signed

Closed this issue · 12 comments

After installing r2u following instructions here:
https://github.com/eddelbuettel/r2u

following instructions for bspm using ubuntu.


sudo add-apt-repository ppa:marutter/rrutter4.0   # R v4.0 and higher
sudo add-apt-repository ppa:c2d4u.team/c2d4u4.0+  # R packages

I got an error with keys so i cannot install bspm


 The repository 'https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ 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.
W: GPG error: https://r2u.stat.illinois.edu/ubuntu focal Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A1489FE2AB99A21A
E: The repository 'https://r2u.stat.illinois.edu/ubuntu focal Release' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.

Try following the setup script for focal in my r2u repo which uses bspm (as a recommended option) -- it covers the key setup.

I have used the script in the meantime to no avail. sorry
More specifically, this line of the script is timeout:
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A

Please show a reproducible failure. I believe I tested this quite extensively under Docker, and we have lots of user -- about half the activity seems to be on focal (yet I prefer jammy because very generally, newer is better).

Here is the (truly minimal !) existence proof:

edd@rob:~$ docker run --rm -ti eddelbuettel/r2u:focal apt update
Ign:1 https://r2u.stat.illinois.edu/ubuntu focal InRelease
Get:2 https://r2u.stat.illinois.edu/ubuntu focal Release [5,713 B]                                 
Get:3 https://r2u.stat.illinois.edu/ubuntu focal Release.gpg [793 B]                                                                
Hit:4 http://archive.ubuntu.com/ubuntu focal InRelease                                                                              
Get:5 http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu focal InRelease [18.1 kB]               
Get:6 https://r2u.stat.illinois.edu/ubuntu focal/main all Packages [6,890 kB]   
Get:7 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]                                        
Get:8 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]                                                      
Get:9 https://r2u.stat.illinois.edu/ubuntu focal/main amd64 Packages [2,217 kB]                                                                                     
Hit:10 http://ppa.launchpad.net/edd/misc/ubuntu focal InRelease                                                                                                                
Hit:11 http://ppa.launchpad.net/edd/r-4.0/ubuntu focal InRelease                                                                              
Get:12 http://archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB] 
Get:13 http://security.ubuntu.com/ubuntu focal-security/multiverse amd64 Packages [27.7 kB]
Get:14 http://archive.ubuntu.com/ubuntu focal-updates/restricted amd64 Packages [1,894 kB]
Get:15 http://ppa.launchpad.net/marutter/rrutter4.0/ubuntu focal InRelease [17.5 kB]        
Get:16 http://security.ubuntu.com/ubuntu focal-security/universe amd64 Packages [972 kB]                 
Get:17 http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu focal/main amd64 Packages [1,123 kB]                        
Get:18 http://archive.ubuntu.com/ubuntu focal-updates/multiverse amd64 Packages [30.4 kB]                               
Get:19 http://archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1,275 kB]                                       
Get:20 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2,358 kB]                                         
Get:21 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [2,828 kB]                                               
Get:22 http://archive.ubuntu.com/ubuntu focal-backports/universe amd64 Packages [28.6 kB]                                          
Get:23 http://archive.ubuntu.com/ubuntu focal-backports/main amd64 Packages [55.2 kB]                                               
Get:24 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 Packages [1,779 kB]                                       
Get:25 http://ppa.launchpad.net/marutter/rrutter4.0/ubuntu focal/main amd64 Packages [8,934 B] 
Fetched 21.9 MB in 2s (11.8 MB/s)                      
Reading package lists... Done
Building dependency tree       
Reading state information... Done
46 packages can be upgraded. Run 'apt list --upgradable' to see them.
edd@rob:~$ 

The container is public, as is its creation script.

This line of the script is timeout:

~  sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A                                         100 ✘  took 8s    base    at 17:34:12   
Executing: /tmp/apt-key-gpghome.gH2hrLeAqk/gpg.1.sh --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A
gpg: keyserver receive failed: Connection timed out

This must be some issue with WSL2 or your Windows firewall. Try this: https://unix.stackexchange.com/a/399091

Spot on, @Enchufa2. The server is just fine:

edd@rob:~$ docker run --rm -ti eddelbuettel/r2u:focal bash
root@36dd1b1ed6b0:/# apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A
Executing: /tmp/apt-key-gpghome.3RgGXxMfBZ/gpg.1.sh --keyserver keyserver.ubuntu.com --recv-keys A1489FE2AB99A21A
gpg: key A1489FE2AB99A21A: "Dirk Eddelbuettel <edd@debian.org>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1
root@36dd1b1ed6b0:/# 

Executing: /tmp/apt-key-gpghome.WfE98tHk1H/gpg.1.sh --keyserver keyserver.ubuntu.com:80 --recv-keys A1489FE2AB99A21A
gpg: keyserver receive failed: No keyserver available

Do it on a non-handicapped machine, export the key to ascii armor, scp that into you WSL box and inject it by hand.

You have a WSL2 bug. That prevents you from executing the r2u instructions, and bspm is just a bystander.

Executing: /tmp/apt-key-gpghome.WfE98tHk1H/gpg.1.sh --keyserver keyserver.ubuntu.com:80 --recv-keys A1489FE2AB99A21A gpg: keyserver receive failed: No keyserver available

It should be hkp://keyserver.ubuntu.com:80. Follow the instructions carefully, please.

@Enchufa2 that did the trick. Now I have the key but the error changed.


Err:5 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 51716619E084DAB9

did one by one. Now working
thanks

Different repo, different signing key: 51716619E084DAB9

Maybe see the instructions there for the key, the longer / fuller README is https://cloud.r-project.org/bin/linux/ubuntu/fullREADME.html, the shorter one is https://cloud.r-project.org/bin/linux/ubuntu/