Limiting number of interactive apps

Hi, just curious if there’s a way within OnDemand to limit the number of interactive apps users are allowed to launch? We’d like to limit the number of concurrent Jupyter jobs for instance. We have occasional issues with users launching 4 different Jupyter jobs and maxing out resource requests for each session, then the sessions undoubtedtly sit idle and chew up resources for others in the queue. We’d also like to nudge people into submitting sbatch scripts once they’ve debugged what they need to in Jupyter. Any suggestions are appreciated.

Generally we’d recommend you try to handle that via your resource manager (i.e. SLURM, TORQUE/PBS, etc). That’s fundamentally what the purpose of such software is, so if you try to hack something together within Open OnDemand you end up with the complexity of trying to figure out how they are interacting and whether any particular problem is due to one or the other software configuration.

Thanks Alan. Sorry about the delay in updating. We found a Slurm option (singleton) that we have implemented, where a job can only begin execution after any previously launched jobs sharing the same job name and user have been terminated, this has been a really straightforward way for us to limit Jupyter sessions to one active job at a time. I appreciate the response.

I use slurm qos limits so that you can only have 3 jobs with max 64GB of RAM between them in the interactive partition. The interactive partition has a priority boost over the regular compute partition. This is my version of nudging people to use sbatch.