19.5 Modify Lock Manager Startup Options

Every ClearCase LT server must run a single lock manager process, which controls database access for every VOB on the system. The lock manager runs with a default set of startup options that are intended to deliver good performance under a wide range of loads. However, you may want to experiment with changing certain lock manager startup options on VOB server hosts that support many VOBs or many users.

Lock Manager Implementations

There are two implementations of the lock manager: one reads and writes data using a socket, the other, which is available on certain UNIX platforms, uses shared memory, which results in lower latency for each request. In many cases, the shared memory implementation can provide better performance on hosts that must support many VOBs and/or many concurrent users. You can tell which type of lock manager is on a system by examining its startup message in lockmgr_log file. The conventional lock manager prints the following lines:

db_VISTA Version 3.20
Database Lock Manager for UNIX BSD

The shared memory lock manager prints the following lines:

db_VISTA Version 3.20
Database Lock Manager for UNIX System V shared memory

Lock Manager Startup Options

On UNIX platforms, lock manager startup options are defined in the startup script ccase-home-dir/etc/atria_start. To change these values, open the startup script in a text editor and edit the command that starts lockmgr:

${ATRIA}/etc/lockmgr ...

On Windows platforms, lock manager startup options are defined internally. To change these defaults, create the following Windows registry key as a REG_SZ value:

HKEY_LOCAL_MACHINE\SOFTWARE\Atria\ClearCase\CurrentVersion
LockMgrCmdLine: REG_SZ : -a almd -f num -u num -q num

NOTE: If you change any lock manager startup option on UNIX or Windows, you must stop and re-start ClearCase on the host before the change will take effect.

SPECIFYING THE LOCKMGR SOCKET. Default: almd

-a almd

Specifies the name of the socket or shared memory file created by the lockmgr. Do not change this name.

SPECIFYING THE NUMBER OF FILES. Default on Windows: 128. Default on UNIX: 256.

-f num

Specifies the number of database files that can be open concurrently. Each VOB database consists of seven database files. The default startup values allow the lock manager to handle a maximum of 36 VOBs on a UNIX host and 18 on a Windows host. If there are more VOBs on the host, the lock manager will not be able to service requests for all of the VOBs concurrently. User response times will degrade, and the db_server or vobrpc_server log files will include messages of the form:
Error: Too many open databases on host (try increasing the -f argument on lockmgr command line).
When this happens, you should either move some of the VOBs to another host, or increase the value of the -f option to 7*V where V represents the number of VOBs on the host.

SPECIFYING THE NUMBER OF USERS. Default on Windows: 128. Default on UNIX: 256

-u num

Specifies the number of db_server or vobrpc_server processes that can concurrently request locks. Each active view requires one vobrpc_server process for each VOB that the view accesses. In addition, various operations that change VOB metadata cause a db_server process to access the VOB through the lock manager. Poor user response time and messages of the form
db_VISTA database -922: lockmgr is busy
in the lockmgr_log file may indicate that the value of the -u option should be raised.
On hosts that do not support the shared-memory lock manager, the -u option cannot be set higher than 1018. On hosts that support the shared-memory lock manager, the -u option is bounded only by available virtual memory.
You can compute an approximate worst case value for -u using the formula:
V*(N/4 + 5)
where V is the number of VOBs on the host, and N is the number of users who access those VOBs. For a more realistic value-one that will not cause the lock manager to consume unnecessary virtual memory on the VOB server host-monitor the total number of vob_server and vobrpc_server processes running on the VOB server host for an extended period of typical use (perhaps a week or two), then multiply the peak value by a factor that will accommodate growth (two, or perhaps a little more).

SPECIFYING THE SIZE OF THE REQUEST QUEUE. Default on Windows: 128. Default on UNIX: 1024.

-q num

Specifies the number of lock requests for locks to be queued. The lock manager delays queuing lock requests in excess of this value. Poor user response time and messages of the form
db_VISTA database -922: lockmgr is busy
in the db_server_log or vobrpc_server_log files (and, often, concurrently in a view_log file) may indicate that the value of the -q option should be raised. As a rule, this value should be no greater that five times the value of the -u option.