Installation

r-cran-rserve out of date and causing errors

r-cran-rserve out of date and causing errors

by Benjamin Walter -
Number of replies: 3

Following the instructions on 
  https://webwork.maa.org/wiki/Installation_Manual_for_2.16_on_Ubuntu#Implement_Option_D_.28Rserve.29
I installed webwork and set up an R server on our new Debian 11 server.

While the suggested R test file in
  Library/UBC/STAT/STAT305/set6/hw06_q1.pg
worked fine; other files, in particular those using graphics such as
  Library/UBC/STAT/STAT300/hw06/stat300_hw06_q01.pg
would not work.  The error messages presented in webwork were not very enlightening.

Running the Rserve from command line, I was able to get more meaningful error messages
   Error: long vectors not supported yet: qap_encode.c:36
   Fatal error: unable to initialize the JIT
whenever webwork attempted to load these problems.

Searching online, it appears that this is a bug in the Rserve v1.7.3 included in the CRAN package.  See
  https://github.com/s-u/Rserve/issues/102

I was able to fix this following the instructions posted later in the github thread -- installing the RForge version (v1.8.8) immediately after installing r-cran-rserve, via the command (in R) 
  install.packages("Rserve",,"Http://rforge.net/",type="source")

Since it is unclear when CRAN will update its Rserve package, please update the online webwork installation instructions.... I spent the last three days pulling out my hair over this issue.


 Benjamin Walter

In reply to Benjamin Walter

Re: r-cran-rserve out of date and causing errors

by Arnold Pizer -
Hi Ben,

Thanks for tracking this down. But the fix did not work for me. The original installation is in /usr/lib/R and this is what the R_HOME_DIR in /usr/bin/R points to. However the new installation is in /usr/local/lib/R and is not used.

I first ran R as a regular user and ran the command install.packages('Rserve',,"http://rforge.net/",type="source")
but understandably did not have permission to write so I quit. Then I ran sudo R and did the installation.

What did I do wrong?
In reply to Arnold Pizer

Re: r-cran-rserve out of date and causing errors

by Arnold Pizer -

install.packages("Rserve",lib="/usr/lib/R/site-library","http://rforge.net")

works.

In reply to Benjamin Walter

Re: r-cran-rserve out of date and causing errors

by Arnold Pizer -

Thanks.

The installation instructions and also the instructions for using the virtual machine image and the Amazon Web Services image have been updated.

Thanks again.


Arnie