-K

Submits a job and waits for the job to complete. Sends job status messages to the terminal.

Categories

notify, properties

Synopsis

bsub -K

Conflicting options

Do not use with the following options: -I, -Ip, -IS, -ISp, -ISs, -Is, -IX.

Description

Sends the message "Waiting for dispatch" to the terminal when you submit the job. Sends the message "Job is finished" to the terminal when the job is done. If LSB_SUBK_SHOW_EXEC_HOST is enabled in lsf.conf, also sends the message "Starting on execution_host" when the job starts running on the execution host.

You are not able to submit another job until the job is completed. This is useful when completion of the job is required to proceed, such as a job script. If the job needs to be rerun due to transient failures, bsub returns after the job finishes successfully. bsub exits with the same exit code as the job so that job scripts can take appropriate actions based on the exit codes. bsub exits with value 126 if the job was terminated while pending.