skip to Main Content

I would like an help from an error that I am experiencing after installing R. I followed all steps from "https://cran.r-project.org/bin/linux/ubuntu/fullREADME.html#installing-r" to install R in Ubuntu 24.04 LTS. However, the following error is reported after starting R in my terminal: "/usr/local/lib/R/bin/exec/R: error while loading shared libraries: libicuuc.so.72: cannot open shared object file: No such file or directory". Is there anyway to fix it?

2

Answers


  1. It looks like the lib is not found, try the following steps:

    sudo apt install libicu72
    

    it may also be a path issue, check your path with:

    echo $LD_LIBRARY_PATH
    

    If the path is empty attempt to set it:

    export LD_LIBRARY_PATH=/path/to/libicu/lib:$LD_LIBRARY_PATH  # Replace path with actual location
    R
    
    Login or Signup to reply.
  2. I can run R just fine on some Ubuntu 24.04 containers as for example rocker/r2u:noble:

    $ docker run --rm -ti rocker/r2u:noble bash
    root@ddcecd84f2b5:/# cd
    root@ddcecd84f2b5:~# R
    
    R version 4.4.1 (2024-06-14) -- "Race for Your Life"
    Copyright (C) 2024 The R Foundation for Statistical Computing
    Platform: x86_64-pc-linux-gnu
    
    R is free software and comes with ABSOLUTELY NO WARRANTY.
    You are welcome to redistribute it under certain conditions.
    Type 'license()' or 'licence()' for distribution details.
    
      Natural language support but running in an English locale
    
    R is a collaborative project with many contributors.
    Type 'contributors()' for more information and
    'citation()' on how to cite R or R packages in publications.
    
    Type 'demo()' for some demos, 'help()' for on-line help, or
    'help.start()' for an HTML browser interface to help.
    Type 'q()' to quit R.
    
    > q()
    Save workspace image? [y/n/c]: n
    root@ddcecd84f2b5:~# 
    root@ddcecd84f2b5:~# apt update -qqq
    root@ddcecd84f2b5:~# apt-cache policy r-base-core
    r-base-core:
      Installed: 4.4.1-1.2404.0
      Candidate: 4.4.1-1.2404.0
      Version table:
     *** 4.4.1-1.2404.0 500
            500 https://cloud.r-project.org/bin/linux/ubuntu noble-cran40/ Packages
            100 /var/lib/dpkg/status
         4.4.0-2.2404.0 500
            500 https://cloud.r-project.org/bin/linux/ubuntu noble-cran40/ Packages
         4.3.3-2build2 500
            500 http://archive.ubuntu.com/ubuntu noble/universe amd64 Packages
    root@ddcecd84f2b5:~# 
    

    This is the standard package from the standard R backport at CRAN. What do you have?

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search