Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

cfKillJob

Cluster Functions Helper to Kill Batch Jobs


Description

This function is only intended for use in your own cluster functions implementation.

Calls the OS command to kill a job via system like this: “cmd batch.job.id”. If the command returns an exit code > 0, the command is repeated after a 1 second sleep max.tries-1 times. If the command failed in all tries, an error is generated.

Usage

cfKillJob(
  reg,
  cmd,
  args = character(0L),
  max.tries = 3L,
  nodename = "localhost"
)

Arguments

reg

[Registry]
Registry. If not explicitly passed, uses the default registry (see setDefaultRegistry).

cmd

[character(1)]
OS command, e.g. “qdel”.

args

[character]
Arguments to cmd, including the batch id.

max.tries

[integer(1)]
Number of total times to try execute the OS command in cases of failures. Default is 3.

nodename

[character(1)]
Name of the SSH node to run the command on. If set to “localhost” (default), the command is not piped through SSH.

Value

TRUE on success. An exception is raised otherwise.

See Also


batchtools

Tools for Computation on Batch Systems

v0.9.15
LGPL-3
Authors
Michel Lang [cre, aut] (<https://orcid.org/0000-0001-9754-0393>), Bernd Bischl [aut], Dirk Surmann [ctb] (<https://orcid.org/0000-0003-0873-137X>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.