ICC Home Privacy and Legal Notice LC User Documents Banner

UCRL-WEB-201386

SLURM Reference Manual


SCANCEL Execute Line

SCANCEL dequeues pending or terminates running SLURM-manged jobs (or their individual job steps) by sending the UNIX KILL (9) signal, or, if you so specify, sends to the jobs or their steps any other UNIX signal.

To run SCANCEL type

scancel [options] [joblist]

where
options
is a space-delimited list of SCANCEL filter, mode, or information options explained in the next subsection. If you specify more than one filter (-n, -p, -t, -u) option, the conditions that each imposes are conjoined (jobs must satisfy all filters to be selected).
joblist
is a space-delimited list of SLURM job ID numbers (54321) or job step numbers (54321.3, 54321.4, etc.), as revealed by SQUEUE or SMAP.

SELECTING JOBS.
You can omit all SCANCEL filter options if you specify one or more jobs (or job steps) overtly, and you can omit a joblist if you specify at least one filter option, but you cannot omit both from the SCANCEL excute line. SCANCEL run with no arguments at all simply reports this error message

          error: no job identification provided

and ends immediately.

OWNERSHIP.
Only a job's owner (or a root user) can signal (and hence cancel) a job or job step successfully. Attempts by anyone else to signal a job or job step yield the error message

          error: kill job error on jobid nnnnn

and have no effect on the job.

RESOURCE (RE)ALLOCATION.
Killing a job step with SCANCEL does not terminate the job to which the step belongs and does not release the resources that SLURM has allocated to that job. Killing a whole job (sending it the default KILL signal with SCANCEL), however, does indeed release the job's previous resource allocation.

ENVIRONMENT VARIABLES.
For SCANCEL options -b, -i, -v, and the four filters options (-n, -p, -t, -u), SLURM recognizes a corresponding environment variable of the same name (e.g., SCANCEL_PARTITION). You can make the same decisions by setting those environment variables, but subsequent use of SCANCEL with a command-line option always overrides the environment variable value.



Navigation Links: [ Document List ] [ HPC Home ] [ Next ]