brown-ccv/ccv-ood-apps

Display error is a Desktop session/job is already running on VNC partition

Closed this issue · 1 comments

Currently we limit vnc partition to one job only so users don't start multiple sessions. But the current submit mechanism will still keep on submitting jobs in in background, causing queue to be full and (QOSMaxJobsPerUserLimit)

Jobs for user ccvdemo
Running:
ID       NAME                              PART.  QOS  CPU  WALLTIME    REMAIN      NODES
8235455  sys/dashboard/sys/bc_ccv_vnc_alt  vnc    vnc  8    2-00:00:00  1-23:50:53  node1156
Pending:
ID       NAME                              PART.  QOS  CPU  WALLTIME    EST.START  REASON
8235461  sys/dashboard/sys/bc_ccv_vnc_alt  vnc    vnc  8    2-00:00:00  N/A        (QOSMaxJobsPerUserLimit)
8235462  sys/dashboard/sys/bc_ccv_vnc_alt  vnc    vnc  8    2-00:00:00  N/A        (QOSMaxJobsPerUserLimit)

We need to find a way to throw error, if a job is already running.

This is resolved. SLURM has an 'maxsubmitjobsperuser' option per partition, so I set it to one for VNC. Now when a user clicks on submit again, it automatically throws the error:

sbatch: error: QOSMaxSubmitJobPerUserLimit. 
sbatch: error: Batch job submission failed: Job violates accounting/QOS policy (job submit limit, user's size and/or time limits)

Closing this issue.