[R] Segmentation fault in package rJava on CentOS server

Carlos J. Gil Bellosta cgb at datanalytics.com
Wed May 13 11:13:14 CEST 2009


I just installed rJava on

[root at UG13 ~]# R --version
R version 2.9.0 (2009-04-17)

runing on a

[root at UG13 ~]# cat /etc/redhat-release
CentOS release 5.3 (Final)

This is the output of

[root at UG13 ~]# R CMD javareconf
Java interpreter : /usr/bin/java
Java version     : 1.4.2_18
Java home path   : /usr/java/j2sdk1.4.2_18/jre
Java compiler    : /usr/bin/javac
Java headers gen.: /usr/bin/javah
Java archive tool: /usr/bin/jar
Java library path:
JNI linker flags : -L$(JAVA_HOME)/lib/i386/client
-L$(JAVA_HOME)/lib/i386 -L$(JAVA_HOME)/../lib/i386 -ljvm
JNI cpp flags    : -I$(JAVA_HOME)/../include -I$(JAVA_HOME)/../include/linux

Package rJava got properly installed (there were a number of warnings,
though, in the installation process). However,

> library(rJava)
> .jinit("")

 *** caught segfault ***
address 0xc, cause 'memory not mapped'

 1: .External("RinitJVM", boot.classpath, parameters, PACKAGE = "rJava")
 2: .jinit("")

Whenever I try to interact with Java from R --I am interested in the
RJDBC package--, I get the same segmentation fault at the .jinit call.
In particular, when .jinit calls RinitJVM.

Any ideas?

Best regards,

Carlos J. Gil Bellosta

More information about the R-help mailing list