Platform LSF Administration Guide Version 6.2

Chapter 28
Running Parallel Jobs
Administering Platform LSF
447
Reserving Memory for Pending Parallel Jobs
By default, the rusage string reserves resources for running jobs. Because resources
are not reserved for pending jobs, some memory-intensive jobs could be pending
indefinitely because smaller jobs take the resources immediately before the larger jobs
can start running. The more memory a job requires, the worse the problem is.
Memory reservation for pending jobs solves this problem by reserving memory as it
becomes available, until the total required memory specified on the
rusage string is
accumulated and the job can start. Use memory reservation for pending jobs if memory-
intensive jobs often compete for memory with smaller jobs in your cluster.
Unlike slot reservation, which only applies to parallel jobs, memory reservation applies
to both sequential and parallel jobs.
Configuring memory reservation for pending parallel jobs
Use the RESOURCE_RESERVE parameter in lsb.queues to reserve host memory
for pending jobs, as described in “Memory Reservation for Pending Jobs” on page 345.
lsb.queues
Set the RESOURCE_RESERVE parameter in a queue defined in lsb.queues.
The RESOURCE_RESERVE parameter overrides the SLOT_RESERVE parameter. If
both RESOURCE_RESERVE and SLOT_RESERVE are defined in the same queue,
job slot reservation and memory reservation are enabled and an error is displayed when
the cluster is reconfigured. SLOT_RESERVE is ignored. Backfill on memory may still
take place.
The following queue enables both memory reservation and backfill in the same queue:
Begin Queue
QUEUE_NAME = reservation_backfill
DESCRIPTION = For resource reservation and backfill
PRIORITY = 40
RESOURCE_RESERVE = MAX_RESERVE_TIME[20]
BACKFILL = Y
End Queue
Enabling per-slot memory reservation
By default, memory is reserved for parallel jobs on a per-host basis. For example, by
default, the command:
%
bsub -n 4 -R "rusage[mem=500]" -q reservation myjob
requires the job to reserve 500 MB on each host where the job runs.
To enable per-slot memory reservation, define
RESOURCE_RESERVE_PER_SLOT=y in
lsb.params. In this example, if per-slot
reservation is enabled, the job must reserve 500 MB of memory for each job slot (4 *
500 = 2 GB) on the host in order to run.