If all workloads’ demand for CPU resources can be
met with current resources, WLM satisfies that demand. If however,
demand exceeds supply, WLM uses the “rising tide” model
to allocate CPU resources: At a given priority, WLM attempts to
raise the allocation of the workload with the lowest CPU allocation
to the level of the next lowest allocation. If CPU resources remain,
WLM then raises the allocations for those two groups to the level
of the third lowest group. This process continues at the current
priority until all CPU resource requests have been met or all resources
have been distributed. If requests have been met and resources remain,
WLM continues with the next priority.
Consider Figure 3-2 “CPU
allocation: the rising tide model” with
groups A, B, and C. All groups start with 1 CPU share. At priority
1, only groups A and B are requesting CPU resources. Their requests of
15 and 25 shares are easily satisfied. WLM meets the lowest request
first, granting 14 additional shares to both groups. WLM then grants
an additional 10 shares to group B to meet its higher request. Group C and the default group OTHERS (not shown) both receive 1 share. After satisfying
those CPU resource requests, 58 shares are left.
At priority 2, groups A B, and C all request 60 shares. These requests, of course,
sum to 180 shares—exceeding the available 100 shares. With
the 58 remaining shares, WLM can meet only one of the SLOs. With
all three SLOs at the same priority, WLM attempts to satisfy them
all as much as possible—rather than meet one SLO at the
expense of the other two. The strategy of meeting each SLO as much
as possible is similar to a rising tide lifting all boats: All workloads are
raised to the same CPU allocation.
Group C starts with 1 share. WLM first grants group C an additional 14 shares, raising its allocation
to match the allocation for group A. WLM then adds 10 shares to the allocations for
both A and C, matching that of group B. Now each group has 25 shares. The 24 remaining
shares are distributed evenly among the three groups. The last share
is still being used by the group OTHERS (not shown).
Figure 3-2 “CPU
allocation: the rising tide model” illustrates the
rising tide model. Moving from left to right within a single priority
shows how WLM grants additional CPU resources to the workloads.