I tried to update my packages using update.packages() I got the following message: The downloaded packages are in ?/tmp/RtmpyDYdTX/downloaded_packages? Warning in install.packages(update[instlib == l, "Package"], l, contriburl = contriburl, : 'lib = "/usr/lib/R/library"' is not writable Error in install.packages(update[instlib == l, "Package"], l, contriburl = contriburl, : unable to install package How do I fix this ? -- View this message in context: http://r.789695.n4.nabble.com/package-update-tp3507479p3507479.html Sent from the R help mailing list archive at Nabble.com.
package update
5 messages · eric, Uwe Ligges, JJ Allaire +1 more
On 08.05.2011 19:54, eric wrote:
I tried to update my packages using update.packages() I got the following message: The downloaded packages are in ?/tmp/RtmpyDYdTX/downloaded_packages? Warning in install.packages(update[instlib == l, "Package"], l, contriburl = contriburl, : 'lib = "/usr/lib/R/library"' is not writable Error in install.packages(update[instlib == l, "Package"], l, contriburl = contriburl, : unable to install package How do I fix this ?
If you want to update packages in R's default library in /usr/lib/R/library, you will need root permissions. Uwe Ligges
-- View this message in context: http://r.789695.n4.nabble.com/package-update-tp3507479p3507479.html Sent from the R help mailing list archive at Nabble.com.
______________________________________________ R-help at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
ok, how do I do root permissions from the RStudio GUI ? What is the specific command that allows me to do that when I type ...update.packages() ? Also, why are the packages installing in the first place if I can't write to that location ? Currently running linux ubuntu 10.04 by the way. -- View this message in context: http://r.789695.n4.nabble.com/package-update-tp3507479p3510977.html Sent from the R help mailing list archive at Nabble.com.
2 days later
To run RStudio as root on Ubuntu you would just do: sudo rstudio The packages in /usr/lib/R/library are the ones that came with the base install of R. J.J. Allaire -- View this message in context: http://r.789695.n4.nabble.com/package-update-tp3507479p3517539.html Sent from the R help mailing list archive at Nabble.com.
On 9 May 2011 at 12:57, Uwe Ligges wrote:
| |
| On 08.05.2011 19:54, eric wrote:
| > I tried to update my packages using update.packages()
| >
| > I got the following message:
| >
| > The downloaded packages are in
| > ?/tmp/RtmpyDYdTX/downloaded_packages?
| > Warning in install.packages(update[instlib == l, "Package"], l, contriburl =
| > contriburl, :
| > 'lib = "/usr/lib/R/library"' is not writable
| > Error in install.packages(update[instlib == l, "Package"], l, contriburl =
| > contriburl, :
| > unable to install package
| >
| > How do I fix this ?
|
| If you want to update packages in R's default library in
| /usr/lib/R/library, you will need root permissions.
The way it is meant to work is that "you" (eric, the user) become a member of
the group owning that directory -- and I picked group 'staff' for that.
In the postinst (of the Debian / Ubuntu R packages), this directory is created as
# edd 03 Apr 2003 cf Section 10.1.2 of Debian Policy
if [ ! -e /usr/local/lib/R ]; then
if mkdir /usr/local/lib/R 2>/dev/null; then
chown root:staff /usr/local/lib/R
chmod 2775 /usr/local/lib/R
fi
fi
if [ ! -e /usr/local/lib/R/site-library ]; then
if mkdir /usr/local/lib/R/site-library 2>/dev/null; then
chown root:staff /usr/local/lib/R/site-library
chmod 2775 /usr/local/lib/R/site-library
fi
fi
We could conceivably be fancier and create an R group on the system, but I
felt this is best left to local admins.
Alternatively, if you make that directory owned by 'you' then you don't need
root either.
You can check what group you are part of via 'id'. On my Ubuntu box, I am
member of a few groups:
edd at max:~$ id
uid=1000(edd) gid=1000(edd) groups=1000(edd),4(adm),20(dialout),24(cdrom),27(sudo),44(video),46(plugdev),50(staff),107(lpadmin),115(admin),122(sambashare),124(libvirtd)
edd at max:~$
Hope this helps, Dirk
| Uwe Ligges
|
|
|
| >
| > --
| > View this message in context: http://r.789695.n4.nabble.com/package-update-tp3507479p3507479.html
| > Sent from the R help mailing list archive at Nabble.com.
| >
| > ______________________________________________
| > R-help at r-project.org mailing list
| > https://stat.ethz.ch/mailman/listinfo/r-help
| > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
| > and provide commented, minimal, self-contained, reproducible code.
|
| ______________________________________________
| R-help at r-project.org mailing list
| https://stat.ethz.ch/mailman/listinfo/r-help
| PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
| and provide commented, minimal, self-contained, reproducible code.
Gauss once played himself in a zero-sum game and won $50.
-- #11 at http://www.gaussfacts.com