我正在使用R版本3.1.2(2014-10-31) – 平台上的“南瓜头盔”:x86_64-pc-linux-gnu(64位)。
我有一个问题在R中使用RStudio安装新的软件包。 当我调用install.packages()
函数时,我得到:
Warning in install.packages : system call failed: Cannot allocate memory Warning in install.packages : installation of package 'pastecs' had non-zero exit status The downloaded source packages are in '/tmp/Rtmpi0toFl/downloaded_packages'
我已经通过shell命令安装了R,它工作正常。 我也把swappiness的值降到了10,但我不确定是否与这个问题有关。
提前致谢!
我想通了。 我所有的交换价值。
有几个网页建议减少默认交换使用,以加快Ubuntu。 我做了什么来解决这个问题。
在终端…
#Know the swap value cat /proc/sys/vm/swappiness 10 # Access the swap configuration gksudo leafpad /etc/sysctl.conf # Increase the swap usage to 30 (default is 60) vm.swappiness=30
然后,我重新启动。 愉快地安装软件包没有任何问题。