How to configure the general R package directory on the server?

I have a shared R package directory on the server to maintain consistent package versions for all users. This becomes problematic when someone tries to install a new version of a package that was installed by another user, or they try to install it when this package is downloaded elsewhere. In these cases, R creates the 00LOCK-PackageName directory in the shared package directory, and the permissions are such that the installer does not have write access to many files in the directory. This requires a few people chmod-ind in the directory so that it can be deleted or one of our system administrators did the same.

This is a particularly acute issue as we use R packages to support and deploy our reporting infrastructure. This is what we constantly update and deploy on our shared server.

Are there any settings or programs that facilitate collaborative management of R packages? Any general tips?

+6
source share
2 answers

As a result, our system administrator has a script that:

  • Open permissions for all directories, subdirectories and files in our shared packages directory
  • Removed all directories starting with 00LOCK that were older than 15 minutes.
  • Send every minute

We did not encounter any problems since.

0
source

One common solution is

  • so that everyone is a member of a common group, rapps

  • there is a directory in which you share R packages, belongs to the rapps group, and you want to make it sticky - chmod g=rwt , if I remember correctly

  • set umask by default to /etc/profile or the equivalent to make sure that your default creation mode is actually "g + w"; I used the file /etc/profile.d/local_umask.sh to do this with one command umask u=rwx,g=rwx,o=rx

+3
source

Source: https://habr.com/ru/post/911799/


All Articles