bsubs
| option | description | example |
| -E | Runs the specified job-based pre-execution command on the execution host before actually running the job. | |
| -Ep | Runs the specified job-based post-execution command on the execution host after the job finishes. | |
| -e | Appends the standard error output of the job to the specified file path. | |
| -g | group job | bsus -g /group_job_name |
demo
前处理和后处理(pre/post execution)
bsub -E 'echo pre > pre.${LSB_JOBID}.log' -Ep 'echo post > post.${LSB_JOBID}.log' sleep 10
环境变量LSB_JOBID是LSF为每一个作业设置的专有环境变量,内容为作业ID
bsub -o lsf/`date +%Y%m`/%J.out -e lsf/`date +%Y%m`/%J.err
bjobs
-w:
bqueues
bkill
group
bsub -g /group_job_name
bkill -g /group_job_name 0
获得PID
bsub -q gui -I calibre -drc -batch & pid=$!
获得JOBID
function nk_jobid {
output=$($*)
echo $output | head -n1 | cut -d'<' -f2 | cut -d'>' -f1
}
jobid=$(nk_jobid bsub pwd)
本文介绍了在LSF(LoadSharingFacility)环境下,如何使用bsub命令进行作业调度,包括执行预执行和后执行命令、利用LSB_JOBID环境变量、以及管理组作业、查看队列状态和终止作业的相关操作。
2016

被折叠的 条评论
为什么被折叠?



