I just noticed that the same codes run much faster in R launched from the server's terminal than in Rstudio Server, and the difference is quite significant. For example, I wrote a heavy R script that handles a large amount of data (>10GB). When I ran it from Rstudio Server, it did not complete after waiting for 2 hours. So I interrupted and ran the exact same script directly from R launched from the server's command line, and it completed in less than 10 minutes. I just wonder if this also happens to others and if I'm doing something wrong. I did not attach my script because I think this issue is not specifically related to a code or example and the script is pretty overwhelming.
OS: Ubuntu 18.04
Rstudio Server version: 1.2.5033
R version: 3.6.3