带有 R 3.5.1 的 OpenCPU
OpenCPU with R 3.5.1
从昨天开始一切正常,因为我在 R 3.4.4 中使用了 openCPU。今天我尝试在一个新的 ubuntu 16.04 系统中安装 R 3.5.1,因为我的包有问题。所以我所做的是:
# Repos for R3.5.1
sudo add-apt-repository ppa:marutter/rrutter3.5
sudo add-apt-repository ppa:marutter/c2d4u
# Repos for opencpu
sudo add-apt-repository -y ppa:opencpu/opencpu-2.0
sudo apt-get update && sudo apt upgrade
# Installs OpenCPU server
sudo apt-get install -y opencpu-server
一切似乎都很好,直到我尝试访问 http:/ip/ocpu/test 并且页面从未加载。然后我搜索了apache的errorlog
Error: package ‘unix’ was installed by an R version with different
internals; it needs to be reinstalled for use with this R version
From directive RSourceOnStartup on line 7 of
/etc/apache2/sites-enabled/opencpu.conf. Using locale: en_US.UTF-8
Error: package ‘unix’ was installed by an R version with different
internals; it needs to be reinstalled for use with this R version
From directive RSourceOnStartup on line 7 of
/etc/apache2/sites-enabled/opencpu.conf.
然后我打开一个 R 会话并尝试加载 unix 库,它按预期加载并且没有任何问题。
有什么想法吗? opencpu 和 R 3.5.2 有冲突吗?
实际上,openCPU 有自己的库,位于 /usr/lib/opencpu/library
,这些包需要重新编译。所以我做了以下事情:
pkgs <- as.data.frame(installed.packages(lib.loc="/usr/lib/opencpu/library/"))
pkgs <- as.character(pkgs$Package)
install.packages(pkgs, lib="/usr/lib/opencpu/library/")
现在一切正常。
从昨天开始一切正常,因为我在 R 3.4.4 中使用了 openCPU。今天我尝试在一个新的 ubuntu 16.04 系统中安装 R 3.5.1,因为我的包有问题。所以我所做的是:
# Repos for R3.5.1
sudo add-apt-repository ppa:marutter/rrutter3.5
sudo add-apt-repository ppa:marutter/c2d4u
# Repos for opencpu
sudo add-apt-repository -y ppa:opencpu/opencpu-2.0
sudo apt-get update && sudo apt upgrade
# Installs OpenCPU server
sudo apt-get install -y opencpu-server
一切似乎都很好,直到我尝试访问 http:/ip/ocpu/test 并且页面从未加载。然后我搜索了apache的errorlog
Error: package ‘unix’ was installed by an R version with different
internals; it needs to be reinstalled for use with this R version
From directive RSourceOnStartup on line 7 of
/etc/apache2/sites-enabled/opencpu.conf. Using locale: en_US.UTF-8
Error: package ‘unix’ was installed by an R version with different
internals; it needs to be reinstalled for use with this R version
From directive RSourceOnStartup on line 7 of
/etc/apache2/sites-enabled/opencpu.conf.
然后我打开一个 R 会话并尝试加载 unix 库,它按预期加载并且没有任何问题。
有什么想法吗? opencpu 和 R 3.5.2 有冲突吗?
实际上,openCPU 有自己的库,位于 /usr/lib/opencpu/library
,这些包需要重新编译。所以我做了以下事情:
pkgs <- as.data.frame(installed.packages(lib.loc="/usr/lib/opencpu/library/"))
pkgs <- as.character(pkgs$Package)
install.packages(pkgs, lib="/usr/lib/opencpu/library/")
现在一切正常。