DSMAX field (DSMAX subsystem parameter)
The DSMAX subsystem parameter specifies the maximum number data sets that can be open at one time.
Acceptable values: | 1–400000 |
---|---|
Default: | based on calculations |
Update: | enter a value in the override column |
DSNZPxxx: | DSN6SPRM DSMAX |
- 32768 - 400000
- If the number of open data sets reaches the specified value, new OPEN statements begin to fail with reason code 00C20113. However, when the number of open data sets approaches the specified value, Db2 also begins closing a number of open data sets, starting with the least recently used CLOSE YES data sets.
- 1–32767
- For any value in this range, if the number of open data sets reaches 32,768, new OPEN statements begin to fail with reason code 00C20113. However, when the number of open data sets approaches 32,768, Db2 also begins closing a number of open data sets, starting with the least recently used CLOSE YES data sets.
Although the maximum number of data sets is 400000, the practical limit can be much lower, depending on the available 31-bit storage below the bar in the database services address space (ssnmDBM1). The value that you enter can substantially influence the performance of Db2.
Complete one of the following actions to improve the performance of opening and closing data sets:
- Update the ALLOCxx parmlib member to set the SYSTEM MEMDSENQMGMT value to ENABLE.
- Issue system command SETALLOC SYSTEM,MEMDSENQMGMT=ENABLE.
It is best to update the ALLOCxx parmlib because the change remains effective across IPLs. If the SETALLOC command is used to enable SYSTEM MEMDSENQMGM, you must restart Db2.
When a secondary index is nonpartitioned, the number of data sets that are required for the index is dependent on the total required space to contain the tree structure and on the size limit of each data set. When a secondary index is data-partitioned, the number of data sets that are required for the index is equal to the number of data partitions in the table space that contains the table. Unless a small piece size is used for nonpartitioned secondary indexes, partitioning generally results in an increase in the number of data sets for the index.
If the partitioning of secondary indexes causes the number of data sets to increase or decrease appreciably, you can modify the value of DSMAX. The default value for DSMAX is calculated by Db2 and does not count partitioned objects. Choose the value for DSMAX according to the impact that partitioning secondary indexes has on the number of data sets for those objects. Db2 defers closing and deallocating table spaces or indexes until the number of open data sets reaches the operating system limit or approaches the value that is specified by DSMAX.