AWS Linux Server install R package
Asked Answered
D

4

8

enter image description hereI try to install the package "data.table" (and "aws.s3)" via Rstudio Server on an Amazon Linux instance following this guide: http://stanke.co/category/r/

Unfortunately, I get the following error message. I really don't know what else to do.

Can anybody help? I installed devtools and I am able to install other packages such as xml2, devtools and deplyr.

Dronski answered 17/1, 2018 at 17:58 Comment(1)
I posted a workaround here: https://mcmap.net/q/917807/-r-and-data-table-on-awsTermless
M
5

I had the same issue on AWS and already fixed. You need first install gcc64 and openmp shared support library.

sudo yum install gcc64
sudo yum install libgomp

Then under your user home create an .R folder with a Makevars file in it, with the following content (it will tell to R which compiler to use):

CC = /usr/bin/gcc64
CXX = /usr/bin/g++
SHLIB_OPENMP_CFLAGS = -fopenmp

I hope it's working for you as well ...

Medeah answered 1/2, 2018 at 17:1 Comment(2)
Worked for me. Thanks!Augustaaugustan
I'm afraid this hasn't worked for me - where should I create the .R folder? I have created it where I think it should be (cd ~; mkdir .R) and also in the Sagemaker directory where the notebooks themselves are stored...Ouellette
A
1

You need to install dmlc-core.

This link will provide more information:

A common bricks library for building scalable and portable distributed machine learning

Angiology answered 17/1, 2018 at 18:11 Comment(3)
I did the following already: sudo yum -y install libcurl-devel openssl-devel sudo yum -y install libxml2 libxml2-devel However, the problem is still there. Any idea?Dronski
I don't know enough about the R environment. The problem with your code is that the include file "omp.h" is missing. That file is part of the dmlc-core library.Angiology
Ok thanks so far! What information could I provide, that might help?Dronski
H
1

based on https://github.com/RcppCore/RcppArmadillo/issues/200, I think this issue is due to a g++ compatability issue. It might also explain why when I installed devtools it kept giving me [-Wdeprecated-declarations] so run: sudo yum remove gcc72-c++.x86_64 libgcc72.x86_64

Hautrhin answered 3/5, 2018 at 14:11 Comment(0)
M
0
yum install R-devel

Then you should be able to run the installation command.

Merciless answered 27/4, 2019 at 10:26 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.