done(job_ID | "job_name")
ended(job_ID | "job_name")
exit(job_ID [,[op] exit_code])
exit("job_name"[,[op] exit_code])
external(job_ID | "job_name", "status_text")
job_ID | "job_name"
post_done(job_ID | "job_name")
post_err(job_ID | "job_name")
started(job_ID | "job_name")
exit(job_ID | "job_name"[,[operator] exit_code])
where operator represents one of the following relational operators:
>
>=
<
<=
==
!=
The job state is EXIT, and the job’s exit code satisfies the comparison test.
If you specify an exit code with no operator, the test is for equality (== is assumed).
If you specify only the job, any exit code satisfies the test.
exit (myjob)
The job named myjob is in the EXIT state, and it does not matter what its exit code was.
exit (678,0)
The job with job ID 678 is in the EXIT state, and terminated with exit code 0.
exit ("678",!=0)
The job named 678 is in the EXIT state, and terminated with any non-zero exit code.
If you use job arrays, you can specify additional dependency conditions that only work with job arrays.
To use other dependency conditions with array jobs, specify elements of a job array in the usual way.
bsub -J "JobA" -w 'done(JobB)' command
The simplest kind of dependency expression consists of only one dependency condition. For example, if JobA depends on the successful completion of JobB, submit the job as shown.
-w 'done(312) && (started(Job2)||exit("99Job"))'
The submitted job will not start until the job with the job ID of 312 has completed successfully, and either the job named Job2 has started, or the job named 99Job has terminated abnormally.
-w "210"
The submitted job will not start unless the job named 210 is finished.