Save Restore Doc/Lib Object (SAVRSTDLO)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The Save/Restore Document Library Object (SAVRSTDLO) command saves and restores the following objects to another system. The system must have a supported communication link with the system that the objects are being restored to.

Notes:

  1. When a folder is saved and restored, the folder object is transferred along with the documents contained in that folder and the subfolders and documents in the subfolders and all successively nested folders and documents. Specific folders can be saved and restored individually using the DLO(*FLRLVL) parameter.
  2. Distribution objects (mail) cannot be sent for individual users. Mail can be saved and restored for all users only.
  3. SAVRSTDLO does not require a dedicated system; however, individual objects in use when the save and restore command is issued cannot be saved and restored. To ensure all document library objects are saved and restored, run this command when no office activity is occurring on the system.

Restrictions:

  1. You must have *ALLOBJ or *SAVSYS special authority to use the following parameter combinations on this command:
    • DLO(*ALL) FLR(*ANY)
    • DLO(*CHG)
    • DLO(*MAIL)
    • DLO(*SEARCH) OWNER(*ALL)
    • DLO(*SEARCH) OWNER(user-profile-name)

    where the user profile name specified is not the user profile name of the user issuing the SAVRSTDLO command.

  2. Users that do not have *ALLOBJ or *SAVSYS special authority must:
    • Have *ALL authority for each document or folder to be sent.
    • Be enrolled as Document Interchange Architecture (DIA) users.
  3. This command cannot be used while another job is running commands such as RCLDLO, SAVDLO, and RSTDLO because exclusive use of internal objects may have been obtained by these commands.
  4. Determining document or folder ownership does not include checking group profiles if one is associated with the specified user profile.
  5. Both systems intended to participate in the save and restore operation must be connected to the same APPN network or, if the OptiConnect for I5/OS option is to be used, both systems must be joined by the OptiConnect for I5/OS hardware and software.
Top

Parameters

Keyword Description Choices Notes
DLO Document library object Single values: *ALL, *SEARCH, *CHG, *DOCL, *MAIL, *FLRLVL
Other values (up to 300 repetitions): Character value
Required, Positional 1
RMTLOCNAME Remote location name Name Required, Positional 2
FLR Folder Single values: *ANY, *NONE
Other values (up to 300 repetitions): Character value
Optional
OMITFLR Folders to omit Single values: *NONE
Other values (up to 300 repetitions): Character value
Optional
SRCHTYPE Search type *DOC, *ALL Optional
CHKEXP Expiration date Date, *NO, *CURRENT Optional
CRTDATE Creation date Element list Optional
Element 1: Starting time and date Element list
Element 1: Starting time Time, *AVAIL
Element 2: Starting date Date, *BEGIN, *CURRENT
Element 2: Ending time and date Element list
Element 1: Ending time Time, *AVAIL
Element 2: Ending date Date, *END
DOCCLS Document class Character value, *ANY Optional
OWNER Owner profile Name, *CURRENT, *ALL Optional
REFCHGDATE Last changed date Date, *ANY, *SAVDLOALL Optional
REFCHGTIME Last changed time Time, *ANY Optional
DOCL Document list Character value, *NONE Optional
TGTRLS Target release Simple name, *CURRENT, *PRV Optional
STG Storage *KEEP, *DELETE, *FREE Optional
CMDCHRID Command character identifier Single values: *SYSVAL, *DEVD
Other values: Element list
Optional
Element 1: Graphic character set Integer
Element 2: Code page Integer
SAVACT Save active *NO, *YES Optional
SAVACTWAIT Save active wait time 0-99999, 120, *NOMAX Optional
ASP Auxiliary storage pool ID 1-32, *ANY Optional
NEWOBJ Object name generation *SAME, *NEW Optional
ALWOBJDIF Allow object differences *NONE, *ALL Optional
RSTASP Restore to ASP number 1-32, *SAVASP Optional
Top

Document library object (DLO)

Specifies the document library objects to save. To save a folder, DLO(*ALL) must be specified.

This is a required parameter.

Single values

*ALL
All document library objects further qualified by the FLR parameter are to be saved. Specifying DLO(*ALL) FLR(*ANY) saves all document library objects.
*SEARCH
All document library objects that meet the specified search values are saved. Search values are specified by using the following parameters:
  • Folder (FLR) parameter.
  • Check for mark (CHKFORMRK) parameter.
  • Expiration date (CHKEXP) parameter.
  • Creation date (CRTDATE) parameter.
  • Document class (DOCCLS) parameter.
  • Owner profile (OWNER) parameter.
  • Last changed date (REFCHGDATE) parameter.
  • Last changed time (REFCHGTIME) parameter.

Note: Folders are saved only if SRCHTYPE(*ALL) is specified.

*CHG
All documents created or changed and all folders created since the last complete save operation and all mail is saved.
*SYSOBJNAM
The documents with the system object names specified for the System object name (SYSOBJNAM) parameter are saved.
*DOCL
The list of documents referred to in a document list specified for the Document list (DOCL) parameter is saved.
*MAIL
The distribution objects and documents referred to by a mail log are saved.
*FLRLVL
The folders specified for the Folder (FLR) parameter and documents in the folders are saved. Subfolders are not saved.

Other values (up to 300 repetitions)

document-name
Specify the user-assigned names of the documents that are saved. All documents specified must be in the same folder and that folder must be specified for the Folder (FLR) parameter.

Note: System object name is not supported.

Top

Remote location (RMTLOCNAME)

Specifies the remote location to connect with. Specify the remote location name using the format cccccccc or nnnnnnnn.cccccccc, where nnnnnnnn is the network identifier (ID) and cccccccc is the remote location name.

remote-location-name
Specify the remote location name associated with the system to which you want to restore objects. The local network ID (LCLNETID) network attribute is used as the value of the network identifier.
network-ID.location-name
Specify the network identifier and the remote location name associated with the system to which you want to restore objects.
Top

Folder (FLR)

Specifies the name of the folder to save.

Single values

*ANY
Document library objects can be saved from any folder. Consider the following when using the FLR parameter:
  • FLR(*ANY) is not valid when one of the following is specified:
    • DLO(*DOCL)
    • DLO(*FLRLVL)
    • DLO(document-name)
  • FLR(*ANY) is required when one of the following is specified:
    • DLO(*CHG)
    • DLO(*SYSOBJNAM)
    • DLO(*MAIL)
    • DLO(*SEARCH) SRCHTYPE(*ALL)
  • When SAVDLO DLO(*ALL) FLR(*ANY) is specified, the following are saved:
    • All documents
    • All folders
    • All distribution objects (mail)
*NONE
The documents saved are not in any folder. FLR(*NONE) is valid only when one of the following is specified:
  • DLO(*ALL)
  • DLO(*SEARCH) SRCHTYPE(*DOC)

Other values (up to 300 repetitions)

generic-folder-name
Specify a generic name. A generic name is a character string of one or more characters followed by an asterisk (*); for example, ABC*. The asterisk (*) substitutes for any valid characters. A generic name specifies all objects with names that begin with the generic prefix, for which the user has authority. If an asterisk is not included with the generic (prefix) name, the system assumes it to be the complete object name.
folder-name
Specify the user-assigned name of the folder in which the documents to be saved are located. The folder name can be a maximum of 63 characters in length.
  • Folder objects specified here are saved only when DLO(*ALL) or DLO(*FLRLVL) is specified.
  • FLR(folder-name) is not valid when one of the following is specified:
    • DLO(*SYSOBJNAM)
    • DLO(*MAIL)
    • DLO(*SEARCH) SRCHTYPE(*ALL)
  • Only one folder name can be specified when one of the following is specified:
    • DLO(*DOCL)
    • DLO(*SEARCH) SRCHTYPE(*DOC)
    • DLO(document-name)

Note: System object name is not supported.

Top

Folders to omit (OMITFLR)

Specifies the names of one of more folders, or the generic names of each group of folders, to be excluded from the save operation.

Single values

*NONE
No folders are excluded from the save operation.

Other values (up to 300 repetitions)

generic-folder-name
Specify a generic name. A generic name is a character string of one or more characters followed by an asterisk (*); for example, ABC*. The asterisk (*) substitutes for any valid characters. A generic name specifies all folders with names that begin with the generic prefix, for which the user has authority. If an asterisk is not included with the generic (prefix) name, the system assumes it to be the complete folder name.
folder-name
Specify the name of the folder to be excluded from the save operation.

Note: System object name is not supported.

Top

Search type (SRCHTYPE)

Specifies the type of objects for which to search. This parameter is valid only if *SEARCH is specified for the Document library object (DLO) parameter.

*DOC
Only documents are to be searched and saved.
*ALL
Documents and folders are to be searched and saved.
Top

Expiration date (CHKEXP)

Specifies that all documents with an expiration date before the specified date are to be saved. The expiration date is assigned by the user when a document is created to specify when the document is no longer needed. This parameter is valid only when *SEARCH is specified for the Document library object (DLO) parameter and *DOC is specified for the Search type (SRCHTYPE) parameter.

*NO
The expiration date is ignored.
*CURRENT
All documents with an expiration date before today's date are saved.
date
Specify a document expiration date. All documents with an expiration date before this date are saved.
Top

Creation date (CRTDATE)

Specifies that documents and folders that have a creation date during the time period specified are to be saved. The time period is specified by a starting time and date and an ending time and date. This parameter is valid only when *SEARCH is specified for the Document library object (DLO) parameter. The time period is specified as follows:

((start-time  start-date) (end-time  end-date))

Element 1: Starting time and date

Element 1: Starting time

Use one of the following to specify the starting time. Documents must have been created after this time to be selected. Documents created before this time are not selected.

*AVAIL
Documents and folders filed at any time are eligible for saving.
time
Specify the starting time. When the starting time is used as a search value, the starting date must not be *BEGIN. The starting-time must be the same as the value specified for the Last changed time (REFCHGTIME) parameter when the REFCHGTIME parameter is specified. The time can be specified with or without a time separator:
  • Without a time separator, specify a string of 4 or 6 digits (hhmm or hhmmss) where hh = hours, mm = minutes, and ss = seconds.
  • With a time separator, specify a string of 5 or 8 digits where the time separator specified for your job is used to separate the hours, minutes, and seconds. If you enter this command from the command line, the string must be enclosed in apostrophes. If a time separator other than the separator specified for your job is used, this command will fail.

Element 2: Starting date

Use one of the following to specify the starting date. Documents must have been created on or after this date to be saved. Documents created before this date are not saved.

*BEGIN
Documents and folders are saved regardless of the creation date associated with the object.
*CURRENT
Only documents and folders filed on today's date, after the starting time (if specified), are selected.
date
Specify a starting date for the document creation date time period. The date must be entered in the job date format. The start date must be the same as the value specified for the Last changed date (REFCHGDATE) parameter when the REFCHGDATE parameter is specified.

Element 2: Ending time and date

Element 1: Ending time

Use one of the following to specify the ending time. Documents must have been created before this time to be saved. Any documents created after the specified time are not saved.

*AVAIL
Documents and folders filed at any time are selected for saving.
time
Specify the ending time. When the ending time is to be used as a search value, the ending date must not be *END. See the description of starting-time for details about how time can be specified.

Element 2: Ending date

Use one of the following to specify the ending date. Documents must have been created on or before this date to be saved. Documents created after this date are not saved.

*END
Documents and folders filed on any date are selected. The ending time is not allowed when *END is specified.
date
Specify the ending date for the document creation date time period. Documents created on or before this date are saved. The date must be specified in job date format.
Top

Document class (DOCCLS)

Specifies the class of documents to be saved. The class is assigned by the user when the document is created. This parameter is valid only when *SEARCH is specified for the Document library object (DLO) parameter and *DOC is specified for the Search type (SRCHTYPE) parameter.

Note: Although document classes are user-assigned, double-byte character set (DBCS) data cannot be specified on this parameter.

*ANY
The document class is not used to select documents for saving.
character-value
Specify the document class, ranging from 1 through 16 characters, used to select documents for saving.
Top

Owner profile (OWNER)

Specifies the owner of the documents and folders to be saved. This parameter is valid only when *SEARCH is specified for the Document library object (DLO) parameter.

*CURRENT
Documents and folders owned by the current requester are saved.
*ALL
This parameter is not used to select documents and folders for saving. You must have all object (*ALLOBJ) or save system (*SAVSYS) special authority if *ALL is specified.
name
Specify the name of the user profile that owns the documents and folders to be saved. All documents and folders owned by this user and that meet the other search values specified are saved. *ALLOBJ or *SAVSYS special authority is required if a user profile is selected other than the user profile of the user issuing this command.
Top

Last changed date (REFCHGDATE)

Specifies the date after which the folders that are created and the documents that are changed or created are to be saved. The change date is updated when the document content or description is changed. This parameter is valid only when *SEARCH is specified for the Document library object(DLO) parameter.

*ANY
No reference change date is specified. Documents are saved regardless of the date they were created or changed. Folders are saved regardless of the date they were created.
*SAVDLOALL
Folders that have been created and documents created or changed since that last complete save operation are saved.
date
Specify the date after which the created folders or the created or changed documents are saved.
Top

Last changed time (REFCHGTIME)

Specifies the time, relative to the date specified for the REFCHGDATE parameter, after which the folders that are created and the documents that are changed or created are to be saved. The change time is updated when the document content or description is changed. This parameter is valid only when *SEARCH is specified for the Document library object (DLO) parameter.

*ANY
No time is specified. The documents are saved regardless of the time they were created or changed. Folders are saved regardless of the time they were created.
time
Specify the time after which the created folders or the created or changed documents are saved.

The time can be specified with or without a time separator:

  • Without a time separator, specify a string of 4 or 6 digits (hhmm or hhmmss) where hh = hours, mm = minutes, and ss = seconds.
  • With a time separator, specify a string of 5 or 8 digits where the time separator specified for your job is used to separate the hours, minutes, and seconds. If you enter this command from the command line, the string must be enclosed in apostrophes. If a time separator other than the separator specified for your job is used, this command will fail.
Top

Document list (DOCL)

Specifies a list of documents to be saved. The document list must be in a folder. The name of the folder must be specified using the Folder (FLR) parameter. You must have use (*USE) authority to the folders containing the documents in the document list.

Note: A document list must be the result of a local search, not a remote search.

*NONE
No document list is saved.
character-value
Specify the document list to be saved.
Top

Target release (TGTRLS)

Specifies the release level of the operating system on which you intend to use the object being saved.

When specifying the target-release value, the format VxRxMx is used to specify the release, where Vx is the version, Rx is the release, and Mx is the modification level. For example, V5R3M0 is version 5, release 3, modification 0.

Valid values depend on the current version, release, and modification level of the operating system, and they change with each new release. You can press F4 while prompting this command parameter to see a list of valid target release values.

*CURRENT
The object is to be restored to, and used on, the release of the operating system currently running on your system. The object can also be restored to a system with any subsequent release of the operating system installed.
*PRV
The object is to be restored to the previous release with modification level 0 of the operating system. The object can also be restored to a system with any subsequent release of the operating system installed.
character-value
Specify the release in the format VxRxMx. The object can be restored to a system with the specified release or with any subsequent release of the operating system installed.
Top

Storage (STG)

Specifies whether system storage occupied by the document being saved is kept, deleted, or freed after the save operation ends.

Note: STG(*DELETE) and STG(*FREE) are not valid when any of the following are specified:

*KEEP
The storage occupied by the document remains unchanged after the save operation.
*DELETE
The document object and all search terms are deleted from the system after the save operation.
*FREE
The document description and search terms remain on the system but the storage occupied by the document is deleted after the save operation. The document cannot be used until the document is restored to the system.
Top

Command character identifier (CMDCHRID)

Specifies the character identifier (graphic character set and code page) for the data specified for the Document class (DOCCLS) parameter. The character identifier is related to the display device used to enter the document class.

Single values

*SYSVAL
The system determines the graphic character set and code page values for the command parameters from the QCHRID system value.
*DEVD
The system determines the graphic character set and code page values from the display device description where this command was entered. This option is valid only when entered from an interactive job. If this option is specified in a batch job, an error occurs.

Element 1: Graphic character set

1-32767
Specify the graphic character set to use.

Element 2: Code page

1-32767
Specify the code page to use.
Top

Save active (SAVACT)

Specifies whether an object can be updated while it is being saved.

*NO
Document library objects in use are not saved. Document library objects cannot be updated while being used.
*YES
Document library objects can be changed during the save request.

Note: Some applications update document library objects directly. The data is supplied to the application rather than saving the updates in a temporary file and then updating the DLOs. DLOs that are being updated directly (typically, those being updated by PC-based applications) will not be saved. See the Backup and Recovery information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter for more information on using this parameter.

Top

Save active wait time (SAVACTWAIT)

Specifies the amount of time for an object that is in use, before continuing the save operation. If an object remains in use for the specified time, the object is not saved.

120
The system waits up to 120 seconds for each individual object to become available before continuing the save operation.
*NOMAX
No maximum wait time exists.
0-99999
Specify the number of seconds to wait for each individual object before continuing the save operation.
Top

ASP number (ASP)

Specifies the number of the auxiliary storage pool (ASP) of the document library object (DLO) to be saved.

*ANY
The objects to be saved reside in any ASP. When DLO(*ALL) FLR(*ANY) are specified, all document library objects on the system are saved.

Note:When DLOs from multiple ASPs are saved, multiple tape media files are created. The beginning and ending sequence numbers of these media files will be required on the RSTDLO command to restore all ASPs.

1-32
Specify the number of an existing ASP that contains the document library objects to be saved. ASP 1 is the system ASP.

Note: Mail that has not been filed and documents that are not in a folder reside in the system ASP.

Top

Object name generation (NEWOBJ)

Specifies whether a new library-assigned name and system object name are generated for the folders and documents that are restored.

*SAME
The library-assigned name and system object name do not change.
*NEW
A new library-assigned name and system object name are generated for each document or folder that is restored.
Top

Allow object differences (ALWOBJDIF)

Specifies whether the following differences encountered during a restore operation are allowed.

The ALWOBJDIF parameter can be used to allow an object to be restored whose owner or object name on the system is different than on the media used for the restore operation. By specifying the *ALL special value, an object with a different name is restored to the name on the media, while an object with a different owner keeps the owner name from the system instead of the media.

Note: To use this parameter, you need all object (*ALLOBJ) authority.

*NONE
None of the differences described above are allowed on the restore operation. For authorization list cases, the object is restored, but the object is not linked to the authorization list, and public authority is set to *EXCLUDE. For other cases, a diagnostic message is sent for the object, and the object is not restored.
*ALL
All of the differences described above are allowed for the restore operation. An informational message is sent, and the object is restored.

Notes:

  • If the owners of the object do not match, the object is restored, but it will keep the ownership and authorities of the object on the system before the restore operation.
  • If *ALL is specified on this parameter, *NEW cannot be specified for the Object name generation (NEWOBJ) parameter.
  • If you are restoring objects to a system different from the one on which they were saved and the objects are secured by an authorization list, specifying *ALL automatically links the objects to the authorization list. If the authorization list does not exist on the new system, a message that includes the name of the missing list is issued.
Top

Restore to ASP number (RSTASP)

Specifies the number of the auxiliary storage pool (ASP) on media in which restored documents and folders are to be placed.

*SAVASP
The documents and folders are placed in the same ASP from which they were saved.
1-32
Specify the number of the ASP in which restored documents and folders are placed.
Top

Examples

Example 1: Saving and Restoring All Document Library Objects

SAVRSTDLO   DLO(*ALL)  RMTLOCNAME(SYSTEM1)  FLR(*ANY)
            SAVACT(*YES)  NEWOBJ(*NEW)

This command saves all document library objects located in any folder and restores the objects to a remote system named SYSTEM1. The objects can be changed during the save and restore operation and new names will be given to the libraries in which the objects are restored.

Example 2: Saving and Restoring Specific Document Library Objects

SAVRSTDLO   DLO(*SEARCH)  RMTLOCNAME(SYSTEM2)  FLR(FLR2)
            OWNER(USER8)  SRCHTYPE(*DOC)

This command searches for a folder named FLR2 and checks to see if the documents owned by user USER8. The folder and the documents in the folder are saved and restored on a remote system named SYSTEM2.

Top

Error messages

*ESCAPE Messages

CPCAD82
&1 document library objects saved and restored.
CPFAD8C
An error occurred during the SAVRSTDLO operation.
CPFAD80
Unable to establish connection from &1 to &2.
CPFAD81
User profile &1 not found on remote location &2.
CPFAD82
Remote location &1 not found.
CPFAD83
Remote location &1 cannot be source location.
CPFAD84
ObjectConnect internal error, function code &1, return code &2.
CPFAD86
Location name &1 unable to close &2.
CPFAD88
Unable to establish connection from &1 to &2.
CPFAD93
APPC failure. Failure code is &3.
CPF389C
ObjectConnect internal error, function code &1, return code &2.
Top