LSB_MEMLIMIT_ENF_CONTROL

Syntax

LSB_MEMLIMIT_ENF_CONTROL=<Memory Threshold>:<Swap Threshold>:<Check Interval>:[all]

Description

This parameter further refines the behavior of enforcing a job memory limit. In the case that one or more jobs reach a specified memory limit (both the host memory and swap utilization has reached a configurable threshold) at execution time, the worst offending job will be killed. A job is selected as the worst offending job on that host if it has the most overuse of memory (actual memory rusage minus memory limit of the job).

You also have the choice of killing all jobs exceeding the thresholds (not just the worst).

The following describes usage and restrictions on this parameter.

  • <Memory Threshold>: (Used memory size/maximum memory size)

    A threshold indicating the maximum limit for the ratio of used memory size to maximum memory size on the host.

    The threshold represents a percentage and must be an integer between 1 and 100.

  • <Swap Threshold>: (Used swap size/maximum swap size)

    A threshold indicating the maximum limit for the ratio of used swap memory size to maximum swap memory size on the host.

    The threshold represents a percentage and must be an integer between 0 and 100. If you specify a value of 0, the swap threshold is excluded from memory limit enforcement (that is, there is no limit for swap memory).

  • <Check Interval>: The value, in seconds, specifying the length of time that the host memory and swap memory usage will not be checked during the nearest two checking cycles.

    The value must be an integer greater than or equal to the value of SBD_SLEEP_TIME.

  • The keyword :all can be used to terminate all single host jobs that exceed the memory limit when the host threshold is reached. If not used, only the worst offending job is killed.
  • If the cgroup memory enforcement feature is enabled (LSB_RESOURCE_ENFORCE includes the keyword "memory"), LSB_MEMLIMIT_ENF_CONTROL is ignored.
  • The host will be considered to reach the threshold when both Memory Threshold and Swap Threshold are reached.
  • LSB_MEMLIMIT_ENF_CONTROL does not have any effect on jobs running across multiple hosts. They will be terminated if they are over the memory limit regardless of usage on the execution host.
  • On some operating systems, when the used memory equals the total memory, the OS may kill some processes. In this case, the job exceeding the memory limit may be killed by the OS not an LSF memory enforcement policy.

    In this case, the exit reason of the job will indicate “killed by external signal”.

Default

Not enabled. All jobs exceeding the memory limit will be terminated.