Advance reservation behavior and operations
A job that uses a reservation is subject to all job resource usage limits. Advance reservation preemption allows advance reservation jobs to use the slots that are reserved by the reservation. You can create and use advance reservations for the LSF multicluster capability job forwarding model. Resizable jobs and jobs with compute unit resource requirements can be dispatched only after the advance reservation becomes active.
Job resource usage limits and job chunking
A job that uses a reservation is subject to all job resource usage limits. If a limit is reached on a particular host in a reservation, jobs that use that reservation cannot start on that host.
An advance reservation job is dispatched to its reservation even if the run limit or estimated run time of the job exceeds the remaining active time of the reservation. For example, if a job has a run limit of 1 hour, and a reservation has a remaining active time of 1 minute, the job is still dispatched to the reservation. If the reservation is closed, the job is terminated when the reservation expires.
Similarly, when your job uses chunk job scheduling, advance reservation jobs are chunked together as usual when dispatched to a host of the reservation without regard to the expiry time of the reservation. Chungking occurs even when the jobs are given a run limit or estimated run time. If the reservation is closed, the jobs in WAIT state are terminated when the reservation expires.
Advance reservation preemption
Advance reservation preemption allows advance reservation jobs to use the slots that are reserved by the reservation. Slots that are occupied by non-advance jobs might be preempted when the reservation becomes active.
- The reservation is active.
- At least one job associated with the advance reservation is pending or suspended.
If an advance reservation is modified, preemption is done for an active advance reservation after every modification of the reservation when there is at least one pending or suspended job that is associated with the reservation.
When slots are added to an advance reservation with brsvmod, LSF preempts running non-reservation jobs if necessary to provide slots for jobs that belong to the reservation. Preemption is triggered if pending or suspended jobs belong to the reservation in the system.
When preemption is triggered, non-advance reservation jobs are suspended and their slots that are given to the advance reservation on the hosts that belong to the reservation. On each host, enough non-advance reservation jobs are suspended so that all of slots required by the advance reservation are obtained. The number of slots obtained does not depend on the number of jobs submitted to the advance reservation. Non-advance reservation jobs on a host can only to use slots not assigned to the advance reservation.
When a job is preempted for an advance reservation, it can only resume on the host when either the advance reservation finishes, or some other non-advance reservation job finishes on the host.
For example, a single-host cluster has 10 slots, with 9 non-advance reservation jobs dispatched to the host (each requiring one slot). An advance reservation that uses 5 slots on the host is created, and a single job is submitted to the reservation. When the reservation becomes active, 4 of the non-advance reservation jobs are suspended, and the advance reservation job will start.
Force a job to run before a reservation is active
LSF administrators can use brun to force jobs to run before the reservation is active, but the job must finish running before the time window of the reservation expires.
For example, if the administrator forces a job with a reservation to run one hour before the reservation is active, and the reservation period is 3 hours, a 4 hour run limit takes effect.
Host intersection and advance reservation
When the ENABLE_HOST_INTERSECTION=Y parameter is specified in the lsb.params file, LSF finds any existing intersection with hosts specified in the queue and those specified at job submission by bsub -m and/or hosts with advance reservation. When specifying keywords such as all, allremote, and others, LSF finds an existing intersection of hosts available and the job runs rather than being rejected.
Advance reservations across clusters
You can create and use advance reservation for the LSF multicluster capability job forwarding model. To enable this feature, you must upgrade all clusters to LSF 10 or later.
See IBM Spectrum LSF multicluster capability for more information.
Resizable jobs and advance reservations
Like regular jobs, resizable jobs associated with an advance reservation can be dispatched only after the reservation becomes active, and the minimum processor request can be satisfied. The allocation request is treated like a regular advance reservation job, which relies on slots available to the reservation. If an advance reservation gets more resources by modification (brsvmod addhost), those resources can be used by pending allocation requests immediately.
Advance Reservation | Resizable job | Allocation request | |
---|---|---|---|
One-time expired/deleted | Open | RUN->SSUSP->RUN | Postponed until the job runs |
Closed | Removed | Removed | |
Recurrent expired/deleted | Open | SSUSP till next instance | Postponed until the job runs again in next instance |
Closed | Removed | Removed |
By the time a reservation has expired or deleted, the status change of the resizable job to SSUSP blocks a resizable job allocation request from being scheduled.
Released slots from a resizable job can be reused by other jobs in the reservation.
Resizable advance reservation jobs can preempt non-advance reservation jobs that are consuming the slots that belong to the reservation. Higher priority advance reservation jobs can preempt low priority advance reservation jobs, regardless of whether both are resizable jobs.
Allocation requests of resizable AR jobs honor limits configuration. They cannot preempt any limit tokens from other jobs.
Compute units and advance reservations
Like regular jobs, jobs with compute unit resource requirements and an advance reservation can be dispatched only after the reservation becomes active, and the minimum processor request can be satisfied.
In the case of exclusive compute unit jobs (with the resource requirement cu[excl]), the advance reservation can affect hosts outside the advance reservation but in the same compute unit as follows:
- An exclusive compute unit job dispatched to a host inside the advance reservation will lock the entire compute unit, including any hosts outside the advance reservation.
- An exclusive compute unit job dispatched to a host outside the advance reservation will lock the entire compute unit, including any hosts inside the advance reservation.
Ideally, all hosts belonging to a compute unit should be inside or outside of an advance reservation.