Spencer Graves wrote: > Hi, All: > > Is there a way to identify whether any users are using a > particular package in a shared network R installation? > > I ask, because we have such a multiple-user installation and when > I tried to install a package using Rgui that was in use by Rterm on a > single-user installation, 'install.packages' deleted the existing > package but failed to install the new version; see below. > > I'm concerned especially about the following multiple user > scenario: User A on terminalServer1 tries "install.packages('mvtnorm')" > when user B on terminalServer2 was using 'mvtnorm'; both are using the > same network installation. If the results match my experience on a > single-user installation, the existing version will be deleted but the > new version will NOT be installed. Any subsequent new attempt to access > 'mvtnorm' will fail until all current users of 'mvtnorm' quit those > sessions and someone subsequently invokes
Spencer, I am using a script that asks Windows if a file is opened in a subdirectory of the R library I am going to install or update packages in, which basically uses the Windows shell command net file Then simply grep for the package name you want to install... > "install.packages('mvtnorm')". In fact, user B could have disconnected > from that session a month ago, and may have long forgotten the R session > that is still officially active, though perhaps consuming 0 CPU seconds > in the past month! That's worse and really hard to deal with, I fear. Best wishes, Uwe > Thanks, > Spencer > ####################################### > ## > ## Rgui > ## > ####################################### > R version 2.6.2 (2008-02-08) > <snip> > > utils:::menuInstallPkgs() > trying URL > 'http://cran.cnr.berkeley.edu/bin/windows/contrib/2.6/mvtnorm_0.8-3.zip' > Content type 'application/zip' length 214769 bytes (209 Kb) > opened URL > downloaded 209 Kb > > package 'mvtnorm' successfully unpacked and MD5 sums checked > Warning: cannot remove prior installation of package 'mvtnorm' > > The downloaded packages are in > C:\Documents and Settings\spencerg\Local > Settings\Temp\RtmpghgskA\downloaded_packages > updating HTML package descriptions > > library(mvtnorm) > Error in library(mvtnorm) : there is no package called 'mvtnorm' > > > sessionInfo() > R version 2.6.2 (2008-02-08) > i386-pc-mingw32 > > locale: > LC_COLLATE=English_United States.1252;LC_CTYPE=English_United > States.1252;LC_MONETARY=English_United > States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > > loaded via a namespace (and not attached): > Error in x[["Version"]] : subscript out of bounds > In addition: Warning message: > In FUN(c("mvtnorm", "tools")[[2L]], ...) : > DESCRIPTION file of package 'mvtnorm' is missing or broken > > > ####################################### > ## > ## Concurrent Rterm session > ## > ####################################### > R version 2.6.2 (2008-02-08) > > <snip> > > > dmvnorm(1:2) > [1] 0.01306423 > [1] ".GlobalEnv" "package:mvtnorm" "package:stats" > [4] "package:graphics" "package:grDevices" "package:utils" > [7] "package:datasets" "package:methods" "Autoloads" > [10] "package:base" > > detach() > > dmvnorm(1:2) > Error: could not find function "dmvnorm" > > library(mvtnorm) > Error in library(mvtnorm) : there is no package called 'mvtnorm' > > sessionInfo() > R version 2.6.2 (2008-02-08) > i386-pc-mingw32 > > locale: > LC_COLLATE=English_United States.1252;LC_CTYPE=English_United > States.1252;LC_MONETARY=English_United > States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252 > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > > loaded via a namespace (and not attached): > Error in x[["Version"]] : subscript out of bounds > In addition: Warning message: > In FUN(c("mvtnorm", "stepAICc")[[2L]], ...) : > DESCRIPTION file of package 'mvtnorm' is missing or broken > > > > ______________________________________________ > R-devel@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel ______________________________________________ R-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-devel