There are two ways to start RStudio on Hydra's nodes, you can either run
You can also use Hydra's RStudio Server.
They are both full fledged RStudio, but
Log in Hydra via one of the login nodes, allowing X-tunneling and
qlogin (not qrsh)tools/R/RStudio/desktop modulerstudio --no-sandbox --disable-gpuexitsylvain@login01% qlogin
Your job 2453968 ("QLOGIN") has been submitted
waiting for interactive job to be scheduled ...
Your interactive job 2453968 has been successfully scheduled.
Establishing /cm/shared/apps/uge/var/cm/qlogin_wrapper session to host compute-64-15.cm.cluster ...
Last login: Wed Jul 3 10:17:51 2024 from 192.168.92.121
sylvain@compute-64-15% ml tools/R/RStudio/desktop
Loading tools/R/RStudio/desktop/2024.04.2-764
Loading requirement: tools/R/4.4.1
sylvain@compute-64-15% rstudio --no-sandbox --disable-gpu |
and you should see on your machine, if the X tunnel is set right:

Note that the RStudio desktop does not work with the Windows Xming X-server, but works with Cygwin/X and WSL.
Log in Hydra via one of the login nodes (no need to enable X-tunnel)
qrshtools/R/RStudio/server modulestart-rstudio-serverlocalhost:NNNN, where NNNN is the port number1. Start the server on an interactive node
sylvain@login01% qrsh
sylvain@compute-64-16% module load tools/R/RStudio/server
Loading tools/R/RStudio/server/2024.04.2-764
Loading requirement: tools/R/4.4.1
sylvain@compute-64-16% start-rstudio-server
start-rstudio-server: starting RStudio server on host=compute-64-16 and port=8787
you need to create a ssh tunnel on your local machine with
ssh -N -L 8787:compute-64-16:8787 [email protected]
Point your browser to http://localhost:8787 on your local machine.
Use Control+C in this window to kill the server when done.
TTY detected. Printing informational message about logging configuration. Logging configuration loaded from '/etc/rstudio/logging.conf'. Logging to '/home/sylvain/.local/share/rstudio/log/rserver.log'.
TTY detected. Printing informational message about logging configuration. Logging configuration loaded from '/etc/rstudio/logging.conf'. Logging to '/home/sylvain/.local/share/rstudio/log/rsession-sylvain.log'.
|
[rserver] ERROR system error 98 (Address already in use);",the TCP port is already in use by another user. Specify a different port in the range of 1025-65535 when starting the server. E.g., start-studio-server -port 8890 2. Start the ssh tunnel on your local machine
ssh -N -L 8787:compute-64-16:8787 [email protected] |
8787:compute-64-16:8787 - are likely to be different, andsylvain by your username on Hydra.3. Start a browser on your local machine and go to
http://localhost:8787
you should see:

or

(yse your Hydra credentials).
start-rstudio-server -help to see all the options,You could run either, the server or the desktop, on a login node but we strongly recommend that you use instead an interactive node:
There are resource limits on interactive sessions, tho,
Check the relevant documentation regarding the Interactive Queue under Available Queues.
RStudio uses R version 4.4.1, not 4.4.0
tools/R/4.4.1 module, since loading tools/R load version 4.4.0The RStudio server is by default secured via normal authentication, but
Since only people w/ credentials on Hydra can start a ssh tunnel, you are not exposed to the wide world.
R and Rstudio may need temporary disk space, and in some cases a lot of it./tmp./tmp fills up, a lot of things stop to work, so we recommend that you use a different location for temporary file.TMPDIR , TMP , and TEMP.RStudio, this must be set in an .Renviron file, because the shell's environment in which you start the RStudio server process is not used..Renviron file can be in your home directory or in the base of your RStudio Project directory.TMPDIR=/scratch/genomics/USER/PROJECT/tmp |
where you replace USER and PROJECT by your username and a more specific project name respectively.
Last updated SGK/MPK