Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Restore Configuration (RSTCFG) command restores to the system a configuration object that was saved by the Save System (SAVSYS) or Save Configuration (SAVCFG) command. The types of objects that can be restored by this command are listed on the Object types (OBJTYPE) parameter. The QDFTOWN user profile becomes the default owner of any objects restored on the system whose owner is not known to the system. If an object already exists in the library to which that object is restored, the public and private authorities of the existing object are kept. If the object does not exist in the library, all public authorities are restored, but any private authorities must be given again.
Restrictions:
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
OBJ | Objects | Single values: *ALL, *SRM Other values (up to 300 repetitions): Generic name, name |
Required, Positional 1 |
DEV | Device | Single values: *SAVF Other values (up to 4 repetitions): Name |
Required, Positional 2 |
OBJTYPE | Object types | Single values: *ALL Other values (up to 10 repetitions): *CFGL, *CNNL, *COSD, *CTLD, *DEVD, *LIND, *MODD, *NTBD, *NWID, *NWSD |
Optional, Positional 3 |
VOL | Volume identifier | Single values: *MOUNTED Other values (up to 75 repetitions): Character value |
Optional, Positional 4 |
SEQNBR | Sequence number | 1-16777215, *SEARCH | Optional |
ENDOPT | End of media option | *REWIND, *LEAVE, *UNLOAD | Optional |
SAVF | Save file | Qualified object name | Optional |
Qualifier 1: Save file | Name | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
SRM | System Resource Management | *ALL, *NONE, *HDW, *TRA | Optional |
OPTFILE | Optical file | Path name, * | Optional |
ALWOBJDIF | Allow object differences | Single values: *NONE, *ALL Other values (up to 3 repetitions): *AUTL, *OWNER, *PGP |
Optional |
OUTPUT | Output | *NONE, *PRINT, *OUTFILE | Optional |
OUTFILE | File to receive output | Qualified object name | Optional |
Qualifier 1: File to receive output | Name | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
OUTMBR | Output member options | Element list | Optional |
Element 1: Member to receive output | Name, *FIRST | ||
Element 2: Replace or add records | *REPLACE, *ADD | ||
OMITOBJ | Objects to omit | Values (up to 300 repetitions): Element list | Optional |
Element 1: Object | Qualifier list | ||
Qualifier 1: Object | Generic name, name, *NONE, *ALL | ||
Element 2: Object type | *ALL, *CFGL, *CNNL, *COSD, *CTLD, *DEVD, *LIND, *MODD, *NTBD, *NWID, *NWSD |
Top |
Specifies the objects to be restored. Specify the name of each object, or the generic name of each group of objects to restore. A generic name is a character string that contains one or more characters followed by an asterisk (*). If an asterisk (*) is not specified with the name, the system assumes that the name is a complete object name.
If the Object types (OBJTYPE) parameter has a value of *ALL, all the object types listed in the description of the OBJTYPE parameter are restored, if they have the specified names.
System resource management (SRM) objects cannot be restored individually or by specifying a generic name. To restore only SRM objects, specify *SRM for this parameter and a value for the System Resource Management (SRM) parameter.
This is a required parameter.
Single values
ATTENTION You must specify SRM(*NONE) on the RSTCFG, unless the system you are restoring to is the exact same hardware configuration that the original configuration was saved on, to prevent the restore of the SRM information. If the SRM information is restored, the configuration objects may become unusable.
Other values (up to 300 repetitions)
Note: A generic name is specified as a character string that contains one or more characters followed by an asterisk (*). If a generic name is specified, then all objects that have names with the same prefix as the generic object name are selected.
Top |
Specifies the name of the device used for the restore operation. The device name must already be known on the system by a device description.
This is a required parameter.
Single values
Other values
Top |
Specifies the types of system objects that are to be restored.
Single values
Other values (up to 10 repetitions)
The object types shown are the ones that are saved in the device configuration file by the Save System (SAVSYS) command or the Save Configuration (SAVCFG) command.
Note: *SRMSPC can be saved but not restored as an object type. To restore *SRM data, specify *SRM for the OBJ parameter.
Top |
Specifies the volume identifiers of the media or the cartridge identifiers of tapes in a tape media library device, from which the objects are being restored. The volumes must be in the same order as they were when the data was saved. The volume that contains the beginning of the file to be restored should be placed in the device.
Note: The first version of the objects found in the specified location is restored, unless a specific version is identified by the SAVDATE parameter and SAVTIME parameter, or for tape, the SEQNBR parameter.
Single values
Note: This value cannot be specified when using an optical media library device.
Other values (up to 75 repetitions)
Top |
Specifies the sequence number that is used for the restore operation.
Top |
Specifies the operation that is automatically done on the tape or optical volume after the restore operation ends. If more than one volume is used, this parameter applies only to the last volume used; all other volumes are unloaded when the end of the volume is reached.
Note: This parameter is valid only if a tape or optical device name is specified for the DEV parameter. For optical devices, *UNLOAD is the only special value supported, *REWIND and *LEAVE will be ignored.
Top |
Specifies the save file used to restore the data.
Note: A value must be specified for this parameter if *SAVF is specified for the Device (DEV) parameter.
Qualifier 1: Save file
Qualifier 2: Library
Top |
Specifies the type of system resource management (SRM) information to be restored. This parameter is valid only when *ALL or *SRM is specified on the Objects (OBJ) parameter.
ATTENTION Unless the system you are restoring to has exactly the same hardware configuration as the system that the original configuration was saved on, you must specify SRM(*NONE) on this command to prevent the restore of the SRM information. If the SRM information is restored on a system with a different hardware configuration, the configuration objects may become unusable.
Top |
Specifies the path name of the optical file that is used for the restore operation, beginning with the root directory of the volume.
For more information on specifying path names, refer to "Object naming rules" in the CL concepts and reference topic in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter.
Top |
Specifies whether differences are allowed between the saved objects and the restored objects.
Notes:
The types of differences include:
Note: This parameter has no effect when the saved object did not have an authorization list. If the object exists, it is restored with the authorization list of the existing object. If it does not exist, it is restored with no authorization list.
Single values
Other values (up to 3 repetitions)
If this value is not specified, authorization list differences are not allowed. If the saved object had an authorization list and the object exists on the system but does not have the same authorization list, the object is not restored. If the saved object had an authorization list and the object does not exist and it is being restored to a different system than the save system, the object is restored, but it is not linked to the authorization list, and the public authority is set to *EXCLUDE.
If this value is not specified, ownership differences are not allowed. If an object already exists on the system with a different owner than the saved object, the object is not restored.
If this value is not specified, primary group differences are not allowed. If an object already exists on the system with a different primary group than the saved object, the object is not restored.
Top |
Specifies whether a listing that shows information about the status of the objects is created and directed to an output file. The listing shows the restore information and shows all objects restored, not restored, and excluded. Information about each object's security is listed for the restored objects.
Note: You must specify a database file name for the OUTFILE parameter when OUTPUT(*OUTFILE) is specified.
Top |
Specifies the database file to which the information is directed when *OUTFILE is specified for the Output (OUTPUT) parameter. If the file does not exist, this command creates a database file in the specified library. If a new file is created, the system uses QASRRSTO in QSYS with the format name QSRRST as a model.
Qualifier 1: File to receive output
Qualifier 2: Library
Top |
Specifies the name of the database file member to which the output is directed when *OUTFILE is specified for the Output (OUTPUT) parameter.
Element 1: Member to receive output
If the member exists, you can add records to the end of the existing member or clear the existing member and add the records.
Element 2: Replace or add records
Top |
Specifies the objects to be excluded from the operation. Up to 300 objects or generic object values can be specified.
Element 1: Object
Qualifier 1: Object
Note: A generic name is specified as a character string that contains one or more characters followed by an asterisk (*). If a generic name is specified, then all objects that have names with the same prefix as the generic object name are selected.
Element 2: Object type
To see a complete list of object types when prompting this command, position the cursor on the field for this parameter and press F4 (Prompt). For a description of the object types, see "Object types" in the CL concepts and reference topic in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter.
Top |
Example 1: Restoring All Objects
RSTCFG OBJ(*ALL) DEV(TAP01) OBJTYPE(*ALL)
This command restores all of the device configuration and SRM objects from the tape on the TAP01 drive.
Example 2: Restoring a Device Description
RSTCFG OBJ(PRT01) DEV(TAP01) OBJTYPE(*DEVD) VOL(ABCD)
The device description for PRT01 that was saved on tape volume ABCD is restored to the system. If device description PRT01 already exists on the system, it must be varied off before it can be restored.
Example 3: Restoring a Network Server Description
RSTCFG OBJ(SERVER1) DEV(TAP01) OBJTYPE(*NWSD) VOL(SAV1)
The network server description SERVER1 that was saved on tape volume SAV1 is restored to the system. If the network server description SERVER1 already exists on the system, it must be varied off before it can be restored.
Top |
*ESCAPE Messages
Top |