The DBUTLTY PREINIT function pre-formats (pre-initializes) a data set as an index area or data area for a planned but non-existing index area or data area.
The PREINIT function promotes 24X7 operations. When you do not use PREINIT, adding a new index area or data area to an existing database involves an outage to that database. You have to close the existing database, catalog the definitions for the database, use a DBUTLTY INIT function to initialize (format) the new area, and use a DBUTLTY LOAD or RETIX function to populate the index or data area, which involves a database outage from MUF access. The PREINIT function, however, allows a new index area or data area to be anticipated and initialized before the catalog is done.
The term "catalog" as used here includes CA Datacom Datadictionary catalogs of databases, catalogs of new key definitions, and SQL DDL CREATE statements that add a new index or data area. During the catalog, and if the database currently exists, each index or data area that is found to exist with a known Data Set Name (DSN) is paired with that existing data set. For areas that do not have a known DSN, the list of PREINIT areas is searched for a match. If a match is found, the PREINIT DSN is "taken" and set as the DSN of the area, and the cataloged area is set as initialized and loaded. The process just described occurs for the Index Area (IXX), index areas Inn, and data areas.
Following are some examples related to the use of the PREINIT function that illustrate how PREINIT negates the need to use the INIT, RETIX, and LOAD functions, because you use PREINIT to pre-format a new IXX, or an index area that is not the IXX, or a data area before a database is to be cataloged and where the area is not known by CA Datacom to exist.
Note: Because the PREINIT function is done offline, the database is not opened or referenced. You can, therefore, PREINIT an index or data area for a database that is currently initialized and loaded and that could be in use by open applications. Obviously, you do not want to overlay an existing data set using PREINIT. But you might, for example have a condition where the index area is too small or on a full volume, and you want to make it bigger or just to move it. To have a shorter outage, you can PREINIT the area to the new size and placement while the database is open and is being processed. The outage then might be shorter when you close and remove the old data set name, and catalog the database to pick up the newly initialized data set.
Case 1: Cataloging a database not known to the Directory/CXX
The normal process is to catalog the new database then initialize the index using the INIT function, and initialize the data area(s) using an INIT. Next, load each area using the LOAD function or load the database using LOAD. By using the PREINIT function, you can first pre-initialize the index area(s) and the data area(s), then do the catalog of the database, where the pre-initialized areas are found, with the database set to initialize and load as part of the catalog. The difference could provide value in scheduling the actions.
Case 2: Cataloging a database known to the Directory (CXX) but containing a new data area (and table)
The normal process is to catalog the database and then INIT the data area and LOAD the area. The catalog requires an outage of the data base for a few seconds. If the data area has a few tracks it will quickly be initialized and loaded. For a large area the INIT and LOAD will take some time and this time is occurring with the data base closed. It is possible to use the keyword MULTUSE=YES on the area INIT and LOAD to allow the execution with the base opened. With PREINIT it is possible to initialize and load the area before the catalog and allow the catalog to find the areas and set the new area as initialized and loaded.
Case 3: Add a new key definition to new index area
The normal process is to catalog the database and then INIT the new index area and RETIX the area with MINIMAL=YES to populate the added index. This requires an outage during the catalog and INIT and RETIX functions When a PREINIT of the index area is initialized before there is an outage, the new index definition can be added in a 24x7 way where there is no outage of the database. If using the ‘key’ catalog option of CA Datacom Datadictionary, for example:
-UPD KEY,… 1000 APPLYCXX
Case 4: Add a new table to a new area using SQL
As an example of using SQL, if you were adding a table into a new data area to an existing database using SQL, you could use PREINIT to pre-format a new data area that is to contain a new table that was to be added by using SQL DDL syntax to CREATE the area and table.
Case 5: Adding a new data base using SQL
Another SQL-related example, to add a new database using SQL you can use PREINIT to pre-format a new index and data areas for a planned database that is to be subject to SQL DDL statements, including CREATE BASE, CREATE AREA, and CREATE TABLE
|
Copyright © 2014 CA.
All rights reserved.
|
|