RESTONL: Restore Database from Online Source

The RESTONL function restores a database from a database SAVE data set created while the Adabas nucleus was active.

Notes:

  1. An interrupted RESTONL (database) operation must be reexecuted from the beginning. If the interruption occurred while RESTONL (database) was restoring the PLOG, the restore operation can be completed using the RESTPLOG function. Until successful completion or reexecution of the restore operation, the database is inaccessible.
  2. If the ADASAV RESTONL (database) job control contains the DD names for DDWORKnn, these data sets are reset.

This document covers the following topics:


Conditions

Start of instruction setTo use the RESTONL (database) function, the following conditions must be met:

  1. The correct SAVE data set must be supplied. It must have been created by an online database SAVE operation with the same version of Adabas as is used for the RESTONL.

  2. The output database must have the same physical layout (device types, extent sizes) as the original database. The Associator and Data Storage data sets must be present and must have been previously formatted. The SAVE data set to be restored may have originated for this or from a different database.

  3. No Adabas nucleus may be active on the output database or on a database with the DBID of the output database.

  4. The protection log (PLOG) data set containing information written by the nucleus session at the time of the SAVE operation (see output of SAVE run) must be supplied. PLOG data sets from other sessions may also be included.

  5. If the SAVE operation was performed with the DRIVES parameter, the SAVE data sets created can also be restored with the same DRIVES parameter. Alternatively, the SAVE data sets can be concatenated to a single SAVE data set for a RESTORE operation without the DRIVES parameter which then defaults to DRIVES=1. SAVE datasets can also be arranged in multiple concatenations for use with DRIVES values greater than one. In all cases the data sets must be in ascending order, but the sequence can be broken into separate concatenations at any point,

    For example, a SAVE taken with DRIVES=4 can be restored using DRIVES=1 by concatenating SAVE dataset 1 with 2, 3 and 4 in that order. DRIVES=2 may be used by concatenating dataset 1 with 2 and 3 with 4. When DRIVES is greater than 1, the RESTORE operation is performed from the separate DDRESTn files in parallel.

Result

The result of this function is a database with the same physical status it had at the end of the ADASAV SAVE operation.

Syntax

graphics/util_adasav_restonl.png

Optional Parameters and Subparameters

BUFNO: Count of Buffers Per Drive

The BUFNO value, multiplied by the DRIVES parameter value, allocates fixed buffers for RESTONL operation. A value of 2 or 3 usually provides optimum performance; up to 255 is possible. A value greater than 5, however, provides little advantage and allocates a lot of space. The default is 1 (one buffer per drive).

CLOGDEV: Command Log Device Type

The device type of the dual/multiple command log (CLOG). This parameter is required only if the device type of the CLOG is different from that specified by the ADARUN DEVICE parameter, which is the default.

DRIVES: Tape Drives for Parallel Restore

DRIVES is the number of tape drives to be used for parallel restore processing. The number can range 1 to 8, inclusively; the default is 1.

EXCLUDE: Exclude Specified Files from Restore

EXCLUDE lists the numbers of the files to be excluded from the restore operation; that is, the files that are not to be restored. This list can include a list of more than one Adabas file number or a range of file numbers. Ranges of file numbers should be specified using a dash (-) in the format: fnfirst-fnlast.

The parameter is optional: if not specified, no files are excluded. A file number may be listed only once individually or in a range.

For a database restore:

  • no files specified in the EXCLUDE parameter will exist in the restored database; and

  • all files specified in the EXCLUDE parameter must exist on the save data set (if they are not included in a range of files).

The EXCLUDE parameter is provided for use in recovery jobs built by the Adabas Recovery Aid (ADARAI).

NEWDBID: New ID for Restored Database

NEWDBID may be used to assign a different database ID to the restored database. The ID can be in the range 1-64535; if Adabas Online System Security is installed, DBID 999 is reserved.

If NEWDBID is specified, the ADARUN DBID parameter must specify the ID of the database on the SAVE data set.

No Adabas nucleus may be active with the DBID specified on NEWDBID.

NEWDBNAME: New Name for Restored Database

NEWDBNAME assigns a new name to the restored database. If NEWDBNAME is not specified, the restored database keeps its old name.

NOUSERABEND: Termination without Abend

When a parameter error or a functional error occurs while this utility function is running, the utility ordinarily prints an error message and terminates with user abend 34 (with a dump) or user abend 35 (without a dump). If NOUSERABEND is specified, the utility will not abend after printing the error message. Instead, the message "utility TERMINATED DUE TO ERROR CONDITION" is displayed and the utility terminates with condition code 20.

Note:
When NOUSERABEND is specified, we recommend that it be specified as the first parameter of the utility function (before all other parameters). This is necessary to ensure that its parameter error processing occurs properly.

OVERWRITE: Overwrite Existing Database

If the restore operation is to overwrite an existing database, the OVERWRITE parameter must be specified. No Adabas nucleus may be active on the database to be overwritten.

PLOGDEV: Protection Log Device Type

The device type to be assigned to the dual/multiple protection log (PLOG). This parameter is required only if the device type of the PLOG is different from that specified by the ADARUN DEVICE parameter.

PLOGNUM: Protection Log Number

PLOGNUM specifies the number of the nucleus protection log used while the ADASAV SAVE operation was active (see output listing of the online SAVE function). Sequential protection (SIBA) logs from more than one nucleus session can be concatenated. ADASAV skips protection logs with a number lower than the PLOGNUM value. PLOGNUM is optional.

If PLOGNUM is not specified, ADASAV automatically determines the correct value from information stored in the SAVE data set.

SYN1: Beginning Block Number

SYN1 specifies the block number containing the SYN1 checkpoint at which the corresponding SAVE operation began (see output listing of the online SAVE function). This parameter is optional.

If SYN1 is not specified, ADASAV automatically determines the correct value from information stored in the SAVE data set.

TEST: Test Syntax

The TEST parameter tests the operation syntax without actually performing the operation. Only the syntax of the specified parameters can be tested; not the validity of values and variables.

Examples

Example 1:

ADASAV RESTONL

Restore the database saved when the nucleus was active (online). The protection log number and SYN1 block number required for the restore operation are determined automatically by ADASAV.

Example 2:

ADASAV RESTONL
ADASAV EXCLUDE=255
ADASAV EXCLUDE=400

Files 255 and 400 are excluded from the restore of the database from an online-save data set.