Suggested best practices for resource planning include:
Note that the key to effective resource distribution includes more than configuring suitable plans and policies. You must also ensure that there are enough resources distributed to the resource group(s) in order for the lend/borrow plans to make a difference. A transition from a silo to a distributed model of resource distribution requires a combination of effective resource plan configuration and the appropriate distribution of resources to resource groups in the tree.
The cluster administrator may set aside a number of resources for all consumers within the consumer tree to share. These unowned resources get distributed throughout the tree according to share entitlements (share ratio).
A best practice to help you better leverage the distribution of resources available for sharing is to interpret the share ratio as a minimum share value. These minimum values are complemented by the maximum share values you must also set. A distribution policy that includes resources available for sharing should always yield actual share values between the minimum and maximum constraints. So long as this remains the primary expectation, the complexities of the actual distribution algorithm do not matter.
While a share entitlement is set as a ratio (interpreted as a minimum value for actual share), the maximum share is set as an absolute numerical count.
To avoid confusion, always specify the share entitlement relative to the total number of resources in the share-pool. Doing this results in an equivalence between the share entitlement ratio and the absolute numerical count of shared resources. The resulting perception is of setting absolute numerical counts for both minimum and maximum share.
The number of resources owned by a parent consumer does not need to equal the aggregate number owned by its children. Any surplus resources owned by the parent consumer and not distributed directly to a child are essentially added to a “lending-pool”. Surplus resources are treated differently than shareable resources set aside by cluster administrators:
Surplus resources available for lending can be dedicated to a particular family unit.
The distribution of surplus resources is governed by rank rather than by share entitlement.
Surplus resources cannot be reclaimed by the parent consumer (only resources owned by a leaf consumer can be reclaimed).
Since distribution is first-come/first serve except in cases of competing demand, actual distribution of surplus resources may not reflect the consumer rank settings.
To configure an effective lending-pool of surplus resources, a best practice is to create a low-ranking “imaginary" child (leaf consumer), and to allocate surplus resources to it. Once allocated to this “imaginary” child, surplus resources can be reclaimed from a borrowing child and then lent back out to a higher-ranking child experiencing unsatisfied demand. In this way, actual distribution of surplus resources more closely reflects consumer rank settings.
Configure the “imaginary” child with lowest consumer rank (level 1). This way, the ownership rights of the real children are always met first in cases where there are not enough resources to meet unsatisfied consumer demands. The resources of the “imaginary” child become an effective resource buffer. Furthermore, ensure that the share, maximum share, and maximum lend settings for the “imaginary” child are all set to zero.
In summary, a parent consumer should always allocate all its resources to its children as a best practise. In some cases, parent consumers may assign surplus resources to an “imaginary” child to provide a dynamically varying lend-pool for the real children.
Plan the ranking of your consumers knowing that resources are reclaimed based on their rank; those leaf consumers with a lower consumer rank are reclaimed before consumers with a higher rank.