centos 8 安装好Rstudio server后,登陆 IP:8787 网址显示:
命令行状态报错显示如下:
[root@localhost yangl]# rstudio-server status ● rstudio-server.service - RStudio Server Loaded: loaded (/usr/lib/systemd/system/rstudio-server.service; enabled; vendor preset: disabled) Active: active (running) since Mon 2021-04-19 11:18:40 EDT; 14min ago Process: 124703 ExecStart=/usr/lib/rstudio-server/bin/rserver (code=exited, status=0/SUCCESS) Main PID: 124704 (rserver) Tasks: 3 (limit: 1645654) Memory: 19.1M CGroup: /system.slice/rstudio-server.service └─124704 /usr/lib/rstudio-server/bin/rserver 4月 19 11:18:40 localhost.localdomain systemd[1]: Starting RStudio Server... 4月 19 11:18:40 localhost.localdomain systemd[1]: Started RStudio Server. 4月 19 11:29:08 localhost.localdomain rserver[124965]: ERROR system error 13 (Permission denied); OCCURRED AT rstudio::core::Error rstudio::core::system::launchChildProcess(std::__cxx11::string, std::__cxx11::string, rstudio::core::system::ProcessConfig, rstudio::c>
这个是因为目前Rstudio server 与SELinux不兼容导致,但SELinux 在 RedHat/CentOS/Fedora 及其衍生系统中默认开启导致,解决办法:
默认是开启状态:
[root@localhost yangl]# sestatus SELinux status: enabled SELinuxfs mount: /sys/fs/selinux SELinux root directory: /etc/selinux Loaded policy name: targeted Current mode: enforcing Mode from config file: enforcing Policy MLS status: enabled Policy deny_unknown status: allowed Memory protection checking: actual (secure) Max kernel policy version: 32
关闭SELinux:
[root@localhost yangl]# vi /etc/sysconfig/selinux 将SELINUX=enforcing 改为 SELINUX=disabled
然后重启电脑解决问题!
来源:https://community.rstudio.com/t/rserver-1692-error-system-error-13-permission-denied/46972/10
尊重他人劳动成果,转载请注明出处:Bluesky's blog » RStudio Server: Unable to connect to service