Resuming R session rstudio

Published by onesixx on

큰 Object 작업중에 잠시 쉬었다…. 다시 시작할때… 많이 발생하며,
Session이 죽거나, 기존 Session을 불러오지 못하는 경우에 발생한다.

방법1. 기존 Session을 삭제

 rm -rf ~/.rstudio/sessions/active/session-*

방법2. Session의 timeout시간을 조정

RStudio Server: Configuring the Server

기본적으로 2시간동안 안쓰면, RStudio는 사용자 Session을 suspend하게 되는데,
아래와 같이 30분 또는 무제한으로 suspend되도록 설정 가능함.

$ sudo vi /etc/rstudio/rsession.conf

[user]
session-timeout-minutes=30
[@powerusers]
session-timeout-minutes=0

방법3. Service Restart

~$ sudo systemctl restart rstudio-server

rsession-username ERROR session hadabend

https://moj-analytical-services.github.io/platform_user_guidance/common-errors-and-solutions.html#rsession-username-error-session-hadabend
~$ sudo systemctl status rstudio-server

10월 29 13:50:35 내컴퓨터명
rsession-sixx[1834]: ERROR system error 2 (No such file or directory);
OCCURRED AT: rstudio::core::Error rstudio::session::source_database::get(const string&, boost::shared_ptr) /home/ubuntu/rstudio/src/cpp/session/SessionSourceDatabase.cpp:570; LOGGED FROM: SEXPREC* rstudio::session::modules::r_packages::{anonymous}::rs_getKnitParamsForDocument(SEXP) /home/ubuntu/rstudio/src/cpp/session/modules/SessionRCompletions
1

10월 29 13:55:08 내컴퓨터명
rsession-sixx[13089]: ERROR session hadabend;
LOGGED FROM: rstudio::core::Error {anonymous}::rInit(const rstudio::r::session::RInitInfo&) /home/ubuntu/rstudio/src/cpp/session/SessionMain.cpp:1934

Crash때문에 사용자(sixx)의 session을 restore할수 없음을 나타냄
Crash는 종종 run of memory되었을때 생기면, use pryr 을 사용해서 memory 사용현황을 추적할수 있다. see here.

Categories: R Basic

onesixx

Blog Owner

Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x