I am using a Linux HPC environment to run C++ models. The models require certain modules to be loaded which I have specified through setting up a .profile
file, therefore the modules are always loaded when I log into the HPC through the terminal.
However I would like to run the models when I access the HPC through a visual Rstudio session through the ondemand.HPC software, which runs R as a batch job. I have heard that in this case R is operating through a non-interactive session, which means i need a .bashrc
file to specify the modules which require loading. So I have created both files and left them in my home directory.
Here are my .profile
:
module load nano
module load use.own
module load intel intelmpi dependencies cmake
and .bashrc
files:
module load nano
module load use.own
module load intel intelmpi dependencies cmake
if [ -f ~/.profile ]; then
. ~/.profile
fi
Unfortunately, the modules are still not loaded when opening an batch based visual Rstudio session through OnDemand.HPC. I am a linux rookie therefore any help or tips would be much appreciated.
Thank you for considering this issue.