delta-rho / RHIPE

R and Hadoop Integrated Programming Environment
58 stars 28 forks source link

When attempting to run RHipe 0.75.2 i get a CNF error for org.apache.commons.LogFactory #41

Closed sfines closed 7 years ago

sfines commented 8 years ago

I have tried this with the main branch and when I run Rhinit() I get the following error:

> library(Rhipe)
Loading required package: codetools
Loading required package: rJava
Rhipe: HADOOP_BIN is missing, using $HADOOP/bin
------------------------------------------------
| Please call rhinit() else RHIPE will not run |
------------------------------------------------
> rhinit()
Rhipe: Using Rhipe.jar file
Initializing Rhipe v0.75.2
Error in .jnew("org/godhuli/rhipe/PersonalServer") : 
  java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
myeggo commented 7 years ago

I am having the same issue. Do we have a solution for it? It will be very appreciated if someone can provide help.

hafen commented 7 years ago

Sorry for the delay. This is most likely due to a configuration issue. Unfortunately these things can be difficult to debug since there is so much variability across systems.

In your R session, what do you get when you run Sys.getenv("HADOOP_LIBS")?

If there's nothing in that environment variable, if you are using bash, I'd try creating this environment variable with something like this:

export HADOOP_LIBS=`hadoop classpath | tr -d '*'`

And see if that gets you somewhere.

herychemo commented 7 years ago

Thank you hafen, that is the solution !!! 😄

hafen commented 7 years ago

Great!

Wfore0990 commented 7 years ago

This saved me from my error as well! Thanks hafen!

In my situation I am trying to use Rhipe with Rstudio in a container and had to add the paths that hadoop classpath | tr -d '*' returns to my Renviron file.

magicps5 commented 7 years ago

I'm still having same errors.

Loading required package: codetools Loading required package: rJava

| Please call rhinit() else RHIPE will not run |

rhinit() Rhipe: Using Rhipe.jar file Initializing Rhipe v0.75.2 Error in .jnew("org/godhuli/rhipe/PersonalServer") : java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory Sys.getenv("HADOOP_LIBS") [1] "hadoop classpath | tr -d '*'"