Changing the number of data set groups
Normally, a database is physically stored on one data set or, as in HISAM, on a pair of data sets. However, databases can be physically stored on more than one data set or pair of data sets. If so, each data set or pair of data sets is called a data set group.
You can change to multiple data set groups to tune your database. It is not possible for you to specifically monitor your database to determine whether multiple data set groups will improve performance or better utilize space. Rather, knowledge of your application's requirements along with many types of statistics about database use might help you make this decision.
You can use the database reorganization/load processing utilities (that is, the HISAM Unload/Reload, HD Unload/Reload, Prefix Resolution and Prefix Update utilities) when you change to multiple data set groups and you can use the utilities on one or more databases concurrently. For example, you can reorganize one or more existing databases at the same time that other databases are being initially loaded. Any or all of the databases being operated on can be logically interrelated. A database operation is defined as an initial database load, a database unload/reload (reorganization), or a database scan.
If you are making additional structural changes to a HISAM database other than introducing multiple data set groups (for example, changing the access method from HISAM to HDAM, pointer changes, additional segments, or adding a secondary index), you must follow a procedure similar to that shown in Example flow for HD databases with logical relationships or secondary indexes.
To change the number of data set groups in your database:
Procedure
- Unload your database using the existing DBD.
- If your database is PHDAM or PHIDAM, delete the database definition from the DBRC RECON data sets using the HALDB Partition Definition Utility.
- Code a new DBD.
- Recalculate database space. You need to recalculate database space because the change you are making will result in different requirements for database space.
- Delete the old database space and define new database space for non-VSAM data sets. Delete the space allocated for the old clusters and define space for the new clusters for VSAM data sets.
- If your new database is PHDAM or PHIDAM, run the HALDB Partition Definition utility to define the partition data sets for the database.
- Reallocate data sets because the number and size of data sets you are using will change.
- Reload your database using the new DBD. Take an image copy of your database as soon as the database is reloaded.
- If your database uses logical relationships or secondary indexes, you must run reorganization utilities before and after reloading to resolve prefix information.