Lock escalation is the process of replacing row locks with table locks, reducing the number of locks in the list. This parameter defines a percentage of the lock list held by an application that must be filled before the database managerperforms escalation. When the number of locks held by any one application reaches this percentage of the total lock list size, lock escalation will occur for the locks held by that application. Lock escalation also occurs if the lock list runs out of space.
The database manager determines which locks to escalate by looking through the lock list for the application and finding the table with the most row locks. If after replacing these with a single table lock, the maxlocks value is no longer exceeded, lock escalation will stop. If not, it will continue until the percentage of the lock list held is below the value of maxlocks. The maxlocks parameter multiplied by the maxappls parameter cannot be less than 100.
Recommendation: When setting maxlocks, you should consider the size of the lock list (locklist):
maxlocks = 100 * (512 locks per application * 32 bytes per lock * 2) / (locklist * 4096 bytes)
This sample formula allows any application to hold twice the average number of locks.
You can increase maxlocks if few applications run concurrently since there will not be a lot of contention for the lock list space in this situation.
You may use the database system monitor to help you track and tune this configuration parameter.
The control of lock escalation through this parameter is important to the optimizer since it uses this parameter to determine access paths. You should consider rebinding applications (using the REBIND PACKAGE command) after changing this parameter.