Platform LSF Administration Guide Version 6.2

Counted Host-Locked Licenses
Administering Platform LSF
232
Counted Host-Locked Licenses
Counted host-locked licenses are only available on specific licensed hosts, but also place
a limit on the maximum number of copies available on the host.
Configuring counted host-locked licenses
You configure counted host-locked licenses by having LSF determine the number of
licenses currently available. Use either of the following to count the host-locked licenses:
External LIM (ELIM)
A check_licenses shell script
Using an External
LIM (ELIM)
To use an external LIM (ELIM) to get the number of licenses currently available,
configure an external load index
licenses giving the number of free licenses on each
host. To restrict the application to run only on hosts with available licenses, specify
licenses>=1 in the resource requirements for the application.
See “External Load Indices and ELIM” on page 222 for instructions on writing and
using an ELIM and configuring resource requirements for an application.
See the Platform LSF Reference for information about the
lsf.task file.
Using a
check_license
script
There are two ways to use a check_license shell script to check license availability
and acquire a license if one is available:
Configure the check_license script as a job-level pre-execution command when
submitting the licensed job:
%
bsub -m
licensed_hosts -E check_license licensed_job
Configure the check_license script as a queue-level pre-execution command.
See “Configuring Pre- and Post-Execution Commands” on page 482 for
information about configuring queue-level pre-execution commands.
It is possible that the license becomes unavailable between the time the
check_license script is run, and when the job is actually run. To handle this case,
configure a queue so that jobs in this queue will be requeued if they exit with values
indicating that the license was not successfully obtained.
See “Automatic Job Requeue” on page 387 for more information.