[Rd] error loading library

Oleg Sklyar osklyar at ebi.ac.uk
Tue Feb 26 20:32:27 CET 2008

Could it be connected with the fact that each R session creates an 
Rtmp<smth> directory in tmp (at least on UNIX-alike) and that if started 
simultaneously on machines with the same time stamp they might want to 
use a directory with the same <smth>? It still does not explain the 
behaviour much as, first, loading a package (with a shared object and 
external dependencies) does not seem to cause creation of any files 
there, and, second, I have never experienced such problems of our Linux 
farm although there were situations where I launched about a hundred of 
R session on a farm at the same time. Maybe the external library itself 
uses this temp space and locks it?


Vadim Organovich wrote:
> Hi,
> I am debugging intermittent crashes of R that seem to happen when multiple R sessions nearly summaltaneously load same dll-based library.
> I have R and my libraries installed on a network drive (everything is Windows). The drive is visible from a farm of servers. I have an R script, foo.R, that just loads a dll-based library (to be precise it loads a library that requires a dll-based library). When I start R (via Rscript --vanilla foo.R) from all of the farm computers summaltaneously some of the sessions often crash. It doesn't seem to be specific to the library, I was able to reproduce this with the gbm library as well as with my own library. It feels that the longer it takes to load the library the higher the probability of the crash.
> foo.R :
> library(vmisc)
> The most informative error message I've got so far looks like this, here vmisc dll is the required library that dynamically loads a dll.
> Loading required package: vmiscdll
> Error in file(file, "r") : unable to open connection
> In addition: Warning message:
> In file(file, "r") :
>   cannot open file 'q:/R/vogranovich/library/vmisc/R/vmisc', reason 'Permission denied'
> Error : unable to load R code in package 'vmisc'
> Error: package/namespace load failed for 'vmisc'
> Execution halted
> Exit Code 1 - Process forcefully killed by the TestMaster
> In stand alone sessions, interactive or not, everything loads fine.
> Does loading a library place some sort of a lock?
> I would appreciate any help with this matter.
> Regards,
> Vadim
> 	[[alternative HTML version deleted]]
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel

Dr Oleg Sklyar * EBI-EMBL, Cambridge CB10 1SD, UK * +44-1223-494466

More information about the R-devel mailing list