RStudio
Overview
Using on the wi-hpc
cluster is tricky, but doable. Using apptainer
and The Rocker Project, following this guide, RStudio is available on the wi-hpc
cluster and has the ability to access HPC resources.
Warning
Please be warned that this implementation is still very new and not completed tested. Please report any and all issues to the IT Help Desk.
Getting Started
Load the module to prepare your environment
module load R/rocker_4.5.1
Copy the submission script to a location of your choice
cp $ROCKER/rocker.sh path/to/dest
Edit the rocker.sh
submission file to your perferences.
nano/vi/emacs rocker.sh
Submit the file with sbatch
sbatch rocker.sh
Note
If you want to use GPUs, you must add the following lines to the rocker.sh
script.
...
#SBATCH --partition=gpu
#SBATCH --gres=gpu:x # where x is the number of GPUs you want.
...
# Add the --nv flag to apptainer exec command
apptainer exec --cleanenv \
-- nv \
......
Print out your --error
file to see instructions
1. SSH tunnel from your workstation using the following command:
ssh -N -L 8787:node_number:external_port aharral@wi-hpc
and point your web browser to http://localhost:8787
2. log in to RStudio Server using the following credentials:
user: username
password: xxxxxxxxxxxxxxxxxxxxxxxxxx
When done using RStudio Server, terminate the job by:
1. Exit the RStudio Session ("power" button in the top right corner of the RStudio window)
2. Issue the following command on the login node:
scancel -f <job-id>
Follow the instructions above closely and start using RStudio inside the wi-hpc
cluster.