Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

R XML ERROR: 'configure' exists but is not executable centos 7

I've been having quite a time installing XML on a shiny server. It is currently installed, but I can't quite install it on a separate user, shiny or using sudo.

* installing *source* package ‘XML’ ...
** package ‘XML’ successfully unpacked and MD5 sums checked
ERROR: 'configure' exists but is not executable -- see the 'R Installation 
and Administration Manual'
* removing ‘/home/dalgleishjl/R/x86_64-redhat-linux-gnu-library/3.5/XML’
* restoring previous ‘/home/dalgleishjl/R/x86_64-redhat-linux-gnu- 
library/3.5/XML’

The downloaded source packages are in
    ‘/tmp/RtmpMK29rO/downloaded_packages’
Warning message:
In install.packages("XML") :
  installation of package ‘XML’ had non-zero exit status

attempting it with sudo R has the following result:

trying URL 'https://cloud.r-project.org/src/contrib/XML_3.98-1.11.tar.gz'
Content type 'application/x-gzip' length 1599533 bytes (1.5 MB)
==================================================
downloaded 1.5 MB

* installing *source* package ‘XML’ ...
** package ‘XML’ successfully unpacked and MD5 sums checked
ERROR: 'configure' exists but is not executable -- see the 'R Installation 
and Administration Manual'
* removing ‘/usr/lib64/R/library/XML’

The downloaded source packages are in
    ‘/tmp/RtmpJCIVd4/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done
Warning message:
In install.packages("XML") :
installation of package ‘XML’ had non-zero exit status

I've tried it on the user shiny (sudo -u shiny R):

trying URL 'https://cloud.r-project.org/src/contrib/XML_3.98-1.11.tar.gz'
Content type 'application/x-gzip' length 1599533 bytes (1.5 MB)
==================================================
downloaded 1.5 MB

Error in setwd(od) : cannot change working directory
Error in setwd(startdir) : cannot change working directory
Execution halted

The downloaded source packages are in
        ‘/tmp/Rtmpa7IPyB/downloaded_packages’
Warning message:
In install.packages("XML") :
installation of package ‘XML’ had non-zero exit status

> sessionInfo()
R version 3.5.0 (2018-04-23)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: CentOS Linux 7 (Core)

Matrix products: default
BLAS/LAPACK: /usr/lib64/R/lib/libRblas.so

locale:
[1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
[3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=en_US.UTF-8       LC_NAME=C
[9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

loaded via a namespace (and not attached):
[1] compiler_3.5.0 tools_3.5.0

I've also installed the most recent version of libxml2-devel and libxml2 (using sudo yum install libxml2-devel and sudo yum install libxml2).

like image 628
James Dalgleish Avatar asked Oct 31 '25 03:10

James Dalgleish


1 Answers

It's actually fairly straightforward. Using sudo R to start R, do the following:

dir.create("/home/username/tmp/")
Sys.setenv(TMPDIR="/home/username/tmp/")
install.packages(“XML”)
like image 172
James Dalgleish Avatar answered Nov 02 '25 17:11

James Dalgleish



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!