The values of LOCKS_PER_FILE, MAX_FILES, and MAX_LOCKS are applied to the corresponding executable of each configuration file. That is, the values of the variables defined in the runtime configuration file are applied to the executing client program, and the values defined in the server configuration file are applied to the acuserve process. Remote file access is restricted by the smaller of the two values.
For example, for the following configuration values:
runtime (cblconfig) | MAX_FILES | 64 |
server (a_srvcfg) | MAX_FILES | 32 |
the runtime is able to open 64 files with a limit of 32 remote files.
Alternatively, if the configuration values are:
runtime (cblconfig) | MAX_FILES | 32 |
server (a_srvcfg) | MAX_FILES | 64 |
the runtime will be able to open, at most, 32 remote files.
Determine values for LOCKS_PER_FILE, MAX_FILES, and MAX_LOCKS by noting the values set in cblconfig and then multiplying the value of each variable by the number of runtimes likely to access the server simultaneously. The resultant values are sufficient to support the case where all runtimes have the maximum number of files open with the maximum number of locks applied. The values assigned these variables in a_srvcfg should not be smaller than the values assigned in cblconfig.
For example, if you anticipate having four runtimes accessing the server simultaneously, and the settings of your runtime configuration variables are:
LOCKS_PER_FILE 10 MAX_FILES 30 MAX_LOCKS 40
the corresponding variables in a_srvcfg might be:
LOCKS_PER_FILE 40 MAX_FILES 120 MAX_LOCKS 160
The value of LOCKS_PER_FILE and MAX_FILES in the server configuration file cannot exceed 32767 for Vision files. The value of MAX_LOCKS cannot exceed 8191 for Vision files. To conserve system resources and improve runtime and server performance, set these variables to the smallest value that still meets your requirements.