Avoiding false contention
The Db2 coupling facility lock structure has two parts: a lock table, which is used to determine whether inter-Db2 read/write interest exists on a particular resource, and a list of the update locks that are currently held.
When considering false contention, you must consider the size of the lock table. The total size of the lock structure determines the size of the lock table. Assuming that you specify an INITSIZE value on the CFRM policy that is a power of 2, the lock table is allocated to one-half the total size of the lock structure. The value that you specify for the lock table entries (LTE) parameter in the IRLMPROC or with the MODIFY irlmproc,SET,LTE command can control how the lock structure is partitioned.
The number of members in the group determines the size of each entry in that lock table. IRLM uses the value that you specify in the LOCK ENTRY SIZE field of installation panel DSNTIPJ to determine the initial size of the lock table entries. IRLM also uses the value that you specify in the NUMBER OF LOCK ENTRIES field of installation panel DSNTIPJ to determine how the lock structure is initially partitioned.
IRLM assigns locked resources to an entry value in the lock table. This is how it can quickly check to see if a resource is already locked. If the lock structure is too small (thereby making the lock table portion too small), many locks can be represented by a single value. Thus, false
lock contention can exist. False lock contention is where two different locks on different resources hash to the same lock entry. The second lock requester is suspended until it is determined that no real lock contention exists on the resource.
False contention can be a problem for workloads that have heavy inter-Db2 read/write interest.
One way to reduce false contention is to increase the size of the lock structure or to increase the proportional size of the lock table.