簡體   English   中英

使用Intel MPI在CentOS上安裝Rmpi

[英]Installing Rmpi on centos with intel mpi

我正在嘗試在R的軟件包中安裝Rmpi,並安裝intel mpi。 首先,我下載了Rmpi,並通過以下命令進行了處理:

命令行

R CMD INSTALL --configure-args="--with-mpi=/opt/intel_2015/impi/5.0.1.035/intel64/" Rmpi_0.6-5.tar.gz

但是它沒有安裝,而是顯示以下結果:

日志

* installing to library ‘/home/user/R/x86_64-pc-linux-gnu-library/3.2’
* installing *source* package ‘Rmpi’ ...
** package ‘Rmpi’ successfully unpacked and MD5 sums checked
checking for gcc... icc -std=gnu99
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether icc -std=gnu99 accepts -g... yes
checking for icc -std=gnu99 option to accept ISO C89... none needed
Trying to find mpi.h ...
Found in /opt/intel_2015/impi/5.0.1.035/intel64//include
Trying to find libmpi.so or libmpich.a ...
Found libmpi in /opt/intel_2015/impi/5.0.1.035/intel64//lib
checking for openpty in -lutil... yes
checking for main in -lpthread... yes
configure: error: Unknown type of mpi: use --with-Rmpi-type or RMPI_TYPE to specify it
ERROR: configuration failed for package ‘Rmpi’
* removing ‘/home/user/R/x86_64-pc-linux-gnu-library/3.2/Rmpi’
* restoring previous ‘/home/user/R/x86_64-pc-linux-gnu-library/3.2/Rmpi’

然后我使用了--with-Rmpi-type='MPI2CH'--with-Rmpi-type='OPENMPI'沒有任何效果,我知道一定是mpi類型的問題。 但是我嘗試了所有可以找到的,但仍然無法解決。 建築

  • Centos 6.7最終版
  • R-3.2.3
  • Rmpi_0.6-5

以下是我的.bashrc intel文件

source /opt/intel_2015/bin/compilervars.sh intel64
source /opt/intel_2015/impi/5.0.1.035/bin64/mpivars.sh
source /opt/intel_2015/composer_xe_2015.0.090/mkl/bin/mklvars.sh intel64
source /opt/intel_2015/bin/iccvars.sh intel64

在嘗試以下命令后:

R CMD INSTALL --configure-args="\
--with-Rmpi-include='/opt/intel_2015/impi/5.0.1.035/intel64/include' \
--with-Rmpi-libpath='/opt/intel_2015/impi/5.0.1.035/intel64/lib' \
--with-mpi='/opt/intel_2015/impi/5.0.1.035/intel64' \
--with-Rmpi-type='OPENMPI' " Rmpi_0.6-5.tar.gz

它顯示了以下結果,仍然有些錯誤,但是很有希望:

* installing *source* package ‘Rmpi’ ...
** package ‘Rmpi’ successfully unpacked and MD5 sums checked
checking for openpty in -lutil... no
checking for main in -lpthread... no
configure: creating ./config.status
config.status: creating src/Makevars
** libs
icc -std=gnu99 -I/opt/R-3.2.3MKL/lib64/R/include -DNDEBUG -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -I/opt/intel_2015/impi/5.0.1.035/intel64/include  -DMPI2 -DOPENMPI -I/usr/local/include    -fpic  -ip -O3 -opt-mem-layout-trans=3 -xHost -march=core-avx2 -wd188 -fp-model precise  -c Rmpi.c -o Rmpi.o
icc -std=gnu99 -I/opt/R-3.2.3MKL/lib64/R/include -DNDEBUG -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -I/opt/intel_2015/impi/5.0.1.035/intel64/include  -DMPI2 -DOPENMPI -I/usr/local/include    -fpic  -ip -O3 -opt-mem-layout-trans=3 -xHost -march=core-avx2 -wd188 -fp-model precise  -c conversion.c -o conversion.o
icc -std=gnu99 -I/opt/R-3.2.3MKL/lib64/R/include -DNDEBUG -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -I/opt/intel_2015/impi/5.0.1.035/intel64/include  -DMPI2 -DOPENMPI -I/usr/local/include    -fpic  -ip -O3 -opt-mem-layout-trans=3 -xHost -march=core-avx2 -wd188 -fp-model precise  -c internal.c -o internal.o
icc -std=gnu99 -shared -L/usr/local/lib64 -o Rmpi.so Rmpi.o conversion.o internal.o -L/opt/intel_2015/impi/5.0.1.035/intel64/lib -lmpi
installing to /home/user/R/x86_64-pc-linux-gnu-library/3.2/Rmpi/libs
** R
** demo
** inst
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
* DONE (Rmpi)

請試試這個:

我發現是依賴錯誤。 我的意思是Rmpi如果還是不行OpenMPI被編譯成動態加載的擴展,這是時下默認安裝。 如果您的OpenMPI > = 1.x(對於1.xx的某些安裝),則需要從禁用dlopen的源安裝它。

所以:

嘗試卸載所有MPI接口,使用“ --enabled-shared --disable-dlopen”命令重新安裝OpenMPI ,並且Rmpi應該能夠在R內成功安裝。

R CMD INSTALL Rmpi_0.6-5.tar.gz --configure-args="--with-mpi=/usr/local/ --with-Rmpi-type=OPENMPI --enabled-shared --disable-dlopen"

希望它對您有用。 但不要放棄:)

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM