Where allowed to run: All environments (*ALL) Threadsafe: No |
Parameters Examples Error messages |
The Add Remote Journal (ADDRMTJRN) command associates a remote journal on the target system, as identified by the relational database directory entry, with the specified journal on the source system. The journal on the source system may be either a local journal or another remote journal. A maximum of 255 remote journals may be associated with a single journal on a source system.
When adding a remote journal to a source journal, the remote journal is created on the target system using a combination of the attributes from the source journal and the input parameters provided on this command. The library that the remote journal will be created in must already exist on the target system prior to this command being used on the source system. When created by this command, the remote journal will be created with a journal type of *REMOTE and the remote journal will not have an attached journal receiver.
Note: A receiver will be attached when the remote journal is activated using either the Change Remote Journal (CHGRMTJRN) command, or Change Journal State (QjoChangeJournalState) API.
When adding the remote journal, the remote journal can either be created into the same named library as that of the source journal or into a redirected library on the target system. A redirected library provides a means for remote journals and any of their associated journal receivers to reside in different named libraries on the target system from the corresponding local journal and journal receivers on the local system. When specified, all validation for the journal library on the target system will be performed using the redirected library name. Similarly, the journal receivers that will later be created and associated with this remote journal can either reside in the same library as the source journal receivers on the source system, or into a distinct redirected library name on the target system. The journal receiver library redirection, if desired, must be specified when the remote journal is added using this command.
When adding a remote journal on a target system, two remote journal types can be specified, *TYPE1 and *TYPE2. The remote journal type influences the redirection capabilities, journal receiver restore operations, and remote journal association characteristics.
If the specified journal already exists on the target system, the journal can be associated with the source journal if all of the following are true:
Also, the journal may or may not have an attached journal receiver.
After the remote journal has been successfully added on the target system, the remote journal will have a journal state of *INACTIVE. A journal state of *INACTIVE for a remote journal means that the remote journal is currently not ready to receive journal entries from its source journal on the source system. The Change Remote Journal (CHGRMTJRN) command or Change Journal State (QjoChangeJournalState) API is used to activate a remote journal and start the replication of journal entries from the source journal to the remote journal.
Once a remote journal has been added to a journal, the receiver that was attached to the source journal at the time of running this command or any subsequently attached receivers, will be protected from deletion if all journal entries for a given journal receiver have not yet been replicated to the remote journal. This protection ends when the remote journal is removed using the Remove Remote Journal (RMVRMTJRN) command or Remove Remote Journal (QjoRemoveRemoteJournal) API.
Restrictions:
Top |
Keyword | Description | Choices | Notes |
---|---|---|---|
RDB | Relational database | Name | Required, Positional 1 |
SRCJRN | Source journal | Qualified object name | Required, Positional 2 |
Qualifier 1: Source journal | Name | ||
Qualifier 2: Library | Name, *LIBL, *CURLIB | ||
TGTJRN | Target journal | Single values: *SRCJRN Other values: Qualified object name |
Optional |
Qualifier 1: Target journal | Name | ||
Qualifier 2: Library | Name | ||
RMTRCVLIB | Remote receiver library | Name, *SRCRCVLIB | Optional |
RMTJRNTYPE | Remote journal type | *TYPE1, *TYPE2 | Optional |
MSGQ | Journal message queue | Qualified object name | Optional |
Qualifier 1: Journal message queue | Name, QSYSOPR | ||
Qualifier 2: Library | Name, QSYS | ||
DLTRCV | Delete receivers | *NO, *YES | Optional |
DLTRCVDLY | Delete receiver delay time | 1-1440, 10 | Optional |
TEXT | Text 'description' | Character value, *BLANK | Optional |
Top |
Specifies the name of the relational database directory entry that contains the remote location name of the target system. This name should match the name of the *LOCAL relational database directory entry on the target system.
This is a required parameter.
Top |
Specifies the name of the journal on the source system to which the remote journal is being added, and the library where it resides. The journal on the source system may be either a local journal or another remote journal.
This is a required parameter.
The name of the source journal can be qualified by one of the following library values:
Top |
Specifies the name of the remote journal on the target system.
Top |
Specifies the name of the library for the remote journal receivers on the target system that will be associated with this remote journal.
Top |
Specifies the type of remote journal on the target system. The remote journal type influences the redirection capabilities, journal receiver restore operations, and remote journal association characteristics. See the Journal Management information in the iSeries Information Center at http://www.ibm.com/eserver/iseries/infocenter for detailed descriptions of the differences.
Top |
Specifies the name of the message queue associated with the remote journal. This value is only set for a journal that is created on the target system.
Top |
Specifies whether the system deletes the target journal receivers when they are no longer needed or keeps them on the target system for the user to delete after they have been detached by the target system. This value is only set for a journal that is created on the target system.
Top |
If the system cannot allocate an object needed to delete a journal receiver associated with the remote journal on the target system, this parameter specifies the time (in minutes) to be used to delay the next attempt to delete the target journal receiver. This value is only set for a journal that is created on the target system.
Top |
Specifies the text that briefly describes the remote journal on the target system. This value is only set for a journal that is created on the target system.
Top |
Example 1: Adding a *TYPE1 remote journal, specifying values for the DLTRCV and TEXT parameters.
ADDRMTJRN SRCJRN(LOCLIB/J) RDB(DETROIT) TGTJRN(RMTLIB/J) DLTRCV(*NO) TEXT('Remote Journal Created for Application Z')
This command adds remote journal J in library RMTLIB to journal J in library LOCAL, and the DLTRCV parameter on the remote journal will be *NO, irrespective of the attribute of journal J in library LOCLIB. If journal J in RMTLIB does not already exist, then it is created, otherwise, it is reassociated with journal J in LOCLIB, if it meets the appropriate criteria.
Top |
*ESCAPE Messages
Top |