Account coordinators

PIs have control over who can charge to their account and how much they can charge

Slurm uses account coordinators as users who can directly control accounts. We highly encourage PIs to assign additional coordinators (typically postdocs or grad students) to manage their Slurm lab accounts access.

Attention

The following common tasks can be run by account coordinators.
Please use them with caution.

Access Control

  1. To add a user to your lab’s Slurm account do:

    [user@login-x:~]$ sacctmgr add user panteater account=panteater_lab
    
  2. To remove a user from your lab’s Slurm charge account do:

    [user@login-x:~]$ sacctmgr remove user where user=panteater account=panteater_lab
    

Set User Limits

  1. Check current limits by account or by user

    [user@login-x:~]$ sacctmgr list assoc account=panteater_lab
    [user@login-x:~]$ sacctmgr list assoc user=panteater
    
  2. Limit user’s CPU time on running jobs

    [user@login-x:~]$ sacctmgr modify user panteater set GrpCPURunMins=10000
    
  3. Limit a specific user to have no more than 20 jobs in the system:

    [user@login-x:~]$ sacctmgr modify user where \
                               name=panteater  account=panteater_lab set maxjobs=20
    
  4. Set number of cores per user to 40 CPUs at a time:

    [user@login-x:~]$ sacctmgr modify user panteater set GrpCPUs=40
    

Clear User limits

To clear a previously set limit, reset its value to -1.

  1. Remove user’s job limit

    [user@login-x:~]$ sacctmgr -i modify user where name=panteater set MaxJobs=-1
    

Manage User Jobs

  1. List jobs by account or by user

    [user@login-x:~]$ squeue -A panteater_lab
    [user@login-x:~]$ squeue -u panteater
    
  2. Cancel jobs by job id:

    [user@login-x:~]$ scancel 1234567
    
  3. Cancel all jobs for a specific user:

    [user@login-x:~]$ scancel -u panteater
    
  1. Cancel all running jobs for a specific user:

    [user@login-x:~]$ scancel -u panteater --state=running
    
  2. Cancel all pending jobs for a specific user:

    [user@login-x:~]$ scancel -u panteater --state=pending
    
  3. Cancel all jobs in the account:

    [user@login-x:~]$ scancel -A panteater_la
    
  4. Hold jobs by jobid:

    [user@login-x:~]$ scontrol hold 1234567
    
  5. Hold the job but allow its owner to release it:

    [user@login-x:~]$ scontrol uhold 1234567
    
  6. Remove the job hold:

    [user@login-x:~]$ scontrol release 1234567
    

Check Priority/Fairshare

  1. Display historical fair share usage for account:

    [user@login-x:~]$ sshare -a -l -A panteater_lab
    
  2. Display pending jobs sorted by priority:

    [user@login-x:~]$ squeue -S '-p' --state=pending | less