flux cancel [OPTIONS] [JOBID...]
flux cancel
flux cancel
cancels one or more jobs by raising a job exception of type=cancel. An optional message included with the cancel exception may be provided via the --message
option. Canceled jobs are immediately sent SIGTERM followed by SIGKILL after a configurable timeout (default=5s).
flux cancel
can target multiple jobids by either taking them on the command line, or via the selection options --all
, --user
, or --states
. It is an error to provide jobids on the command line and use one or more of the selection options.
By default --all
will target all jobs for the current user. To target all jobs for all users, use --user=all
(only the instance owner is allowed to use --user=all
). To see how many jobs flux cancel
would kill, use the --dry-run
option.
-n, --dry-run
Do not cancel any jobs, but print a message indicating how many jobs would have been canceled.
-m, --message=NOTE
Set an optional exception note.
-u, --user=USER
Set target user. The instance owner may specify all for all users.
-S, --states=STATES
Set target job states (default: active). Valid states include depend, priority, sched, run, pending, running, active.
-q, --quiet
Suppress output if no jobs match