【问题标题】:/usr/lib64/libstdc++.so.6: version `CXXABI_1.3.8' not found when loading R packages/usr/lib64/libstdc++.so.6:加载 R 包时找不到版本“CXXABI_1.3.8”
【发布时间】:2017-12-07 16:06:07
【问题描述】:

我知道这个问题已经被问过很多次了,但我的情况很特殊:我正在使用一个没有 root 权限但只能使用“module load gcc”“module load mkl”“module load R3.3/mkl" 等等来加载库。

最近我尝试在该集群上的帐户上安装 mxnet,之后一切似乎都正常,但后来我使用“模块加载 R3.3/mkl”而不是“模块加载”从 R3.2 切换到 R3.2 R3.2/mkl”,但现在当我尝试加载像 stringi 这样的 R 包时,它说

库(字符串), dyn.load(file, DLLpath = DLLpath, ...) 中的错误: 无法加载共享对象'/home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.3/stringi/libs/x 86_64/stringi.so': /usr/lib64/libstdc++.so.6:找不到版本“CXXABI_1.3.8”(/home/hpc/pr74ze/ru37wof2/R/x86 需要 _64-pc-linux-gnu-library/3.3/stringi/libs/x86_64/stringi.so) 错误:“stringi”的包或命名空间加载失败

我记得之前试过加载gsl

module list
Currently Loaded Modulefiles:
 1) admin/1.0     3) intel/16.0   5) mpi.intel/5.1   7) R/3.3mkl   9) git/latest  11) gsl/1.16  
 2) tempdir/1.0   4) mkl/11.3     6) lrz/default     8) nano/2.2  10) gcc/4.9

如果我运行以下命令

echo $LD_LIBRARY_PATH
    /usr/lib64:/lrz/mnt/sys.x86_64/compilers/java/jdk1.7.0_51/jre/lib/amd64/server:/usr/lib64:/lrz/mnt/sys.x86
    _64/compilers/java/jdk1.7.0_51/jre/lib/amd64/server:/lrz/sys/libraries/gsl/1.16/lib:/lrz/sys/compilers/gcc
    /4.9.3/lib64:/lrz/sys/compilers/gcc/4.9.3/lib:/lrz/sys/applications/R/3.3.1_MKL/lib64/R/lib/x86_64:/lrz/sy
    s/intel/impi/5.1.3.181/lib64:/lrz/sys/intel/studio2016_u4/compilers_and_libraries_2016.4.258/linux/mkl/lib
    /intel64:/lrz/sys/intel/studio2016_u4/debugger_2016/libipt/intel64/lib:/lrz/sys/intel/studio2016_u4/compil
    ers_and_libraries_2016.4.258/linux/compiler/lib/intel64

如果我尝试安装 RcppZiggurat

* installing *source* package ‘RcppZiggurat’ ...
** package ‘RcppZiggurat’ successfully unpacked and MD5 sums checked
** libs
*** arch - x86_64
icpc -I/lrz/sys/applications/R/3.3.1_MKL/lib64/R/include -I/lrz/sys/applications/R/3.3.1_MKL/lib64/R/include/x86_64 -DNDEBUG -I. -I../inst/include -I/usr/local/include -I"/home/hpc/pr74ze/ru37wof2/R/x86_64-pc-lin
ux-gnu-library/3.3/Rcpp/include" -I"/home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.3/RcppGSL/include"   -fpic  -O3  -c RcppExports.cpp -o RcppExports.o
In file included from /home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.3/RcppGSL/include/RcppGSL.h(25),
                 from RcppExports.cpp(4):
/home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.3/RcppGSL/include/RcppGSLForward.h(26): catastrophic error: cannot open source file "gsl/gsl_vector.h"
  #include <gsl/gsl_vector.h>
                              ^

compilation aborted for RcppExports.cpp (code 4)

但是我应该如何继续找出问题所在呢?

【问题讨论】:

    标签: c++ r linux gcc rcpp


    【解决方案1】:

    注意隐藏在 /home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.3/stringi/libs/x 86_64/stringi.so 中的 3.3 —— 你可能在 3.2 下构建它,所以它位于 /home/hpc/pr74ze/ru37wof2/R/x86_64-pc-linux-gnu-library/3.2 之下。

    您可以通过直接或通过环境变量设置自己的.libPaths() 来克服这个问题——您可能需要~/R/library 之类的东西。详情请见help(Startup)

    【讨论】:

    • 我在 .Renviron 中设置了 RLIB AND R_HOME 变量,但仍然找不到“版本‘CXXABI_1.3.8’(”错误
    猜你喜欢
    • 1970-01-01
    • 2015-10-10
    • 1970-01-01
    • 1970-01-01
    • 2020-02-13
    • 2015-06-05
    • 2017-12-27
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多