Ask Ubuntu Asked on December 27, 2021
I am trying to run sudo apt-get update
, which I understand to be a prerequisite step to update R with the command sudo apt-get install r-base
.
I get as far as this, and then it gets stuck:
Hit:1 http://gb.archive.ubuntu.com/ubuntu xenial InRelease
Hit:2 http://cran.rstudio.com/bin/linux/ubuntu xenial/ InRelease
Hit:3 http://ppa.launchpad.net/marutter/rrutter/ubuntu xenial InRelease
Get:4 http://gb.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
Hit:5 http://dl.google.com/linux/chrome/deb stable InRelease
Get:6 http://gb.archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
Hit:7 http://gb.archive.ubuntu.com/ubuntu xenial-security InRelease
Hit:8 https://cran.ma.imperial.ac.uk/bin/linux/ubuntu bionic-cran40/ InRelease
0% [Connecting to cran.stat.ucla.edu (128.97.86.247)]
After a couple of minutes I get the message Could not connect to cran.stat.ucla.edu:80 (128.97.86.247), connection timed out
My internet connection seems okay.
Based on answers to similar questions, I have tried sudo apt --fix-broken install
– this runs very quickly and gives the last line 0 to upgrade, 0 to newly install, 0 to remove and 9 not to upgrade
. Based on answers to this question, I have tried changing the download server from the default United Kingdom to the ‘select best server’ recommended http://ubuntu.mirrors.ovh.net/ubuntu, and back again, and I have tried adding -o Acquire::ForceIPv4=true
after the apt-get
command. Changing the download server changes the list of Hits and Gets, but it still gets stuck connecting to cran.stat.ucla.edu.
The repository server at http://cran.stat.ucla.edu seems to be down, You can try the repositories given at
https://cran.ma.imperial.ac.uk/bin/linux/ubuntu/README.html
Edit: You can use them by appending
deb https://cloud.r-project.org/bin/linux/ubuntu xenial-cran40/
in
sudo gedit /etc/apt/sources.list
After appending and saving, issue this command
sudo apt-get update
sudo apt-get install r-base
If you get some key error in above commands, issue
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
and repeat update and install commands.
Answered by turbulence on December 27, 2021
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP