LSF Version 7.3 - Administering Platform LSF
Preparing Your Environment to Submit Parallel Jobs to LSF
500 Administering Platform LSF
Preparing Your Environment to Submit Parallel Jobs to LSF
Getting the host list
Some applications can take this list of hosts directly as a command line parameter.
For other applications, you may need to process the host list.
Example The following example shows a /bin/sh script that processes all the hosts in the
host list, including identifying the host where the job script is executing.
#!/bin/sh
# Process the list of host names in LSB_HOSTS
for host in $LSB_HOSTS ; do
handle_host $host
done
Parallel job scripts
Each parallel programming package has different requirements for specifying and
communicating with all the hosts used by a parallel job. LSF is not tailored to work
with a specific parallel programming package. Instead, LSF provides a generic
interface so that any parallel package can be supported by writing shell scripts or
wrapper programs.
You can modify these scripts to support more parallel packages.
For more information, see Submitting Parallel Jobs on page 500
Use a job starter
You can configure the script into your queue as a job starter, and then all users can
submit parallel jobs without having to type the script name. See Queue-Level Job
Starters on page 570 for more information about job starters.
1 To see if your queue already has a job starter defined, run bqueues -l.
Submitting Parallel Jobs
LSF can allocate more than one host or processor to run a job and automatically
keeps track of the job status, while a parallel job is running.
Specify the number of processors
When submitting a parallel job that requires multiple processors, you can specify
the exact number of processors to use.
1 To submit a parallel job, use bsub -n and specify the number of processors the
job requires.
2 To submit jobs based on the number of available job slots instead of the number
of processors, use
PARALLEL_SCHED_BY_SLOT=Y in lsb.params.
For example:
bsub -n 4 myjob