What happens when you restore journaled objects to a different library or directory

The system assigns a unique internal journal identifier (JID) to every object that is journaled.

If you restore a journaled object to a library or directory other than the original library or directory, and the object still exists on the system and continues to be journaled to the same journal, the JID of the restored object is changed. Message CPF70CB — Journal identifier &2 is currently in use is sent to the job log to confirm the changed JID of the restored object.

All the journal entries associated with the media copy of the object have the original JID. You cannot apply these journal entries to the object that was restored to a different library or directory because it has a different JID. For this reason, you should avoid restoring a journaled object to a different library or directory.

For example, in Figure 1, the original object FILEA in LIBX library has an internal journal identifier of Z that is recorded with every journal entry associated with FILEA in LIBX. When FILEA is restored from the media to LIBC library, it is assigned the journal identifier of Y because FILEA still exists in LIBX and continues to be journaled.

Figure 1. Example: Restoring a journaled object to a different library
Example: Restoring a journaled object to a different library

Any journal operation that references an object by name and involves using journal entries requires that the journal identifier of the object and the journal identifier recorded in the journal entries be the same. Because FILEA in LIBC has journal identifier Y, journal entries with journal identifier Z are not associated with the restored FILEA in LIBC. As a result, journal changes that are recorded for FILEA in LIBX cannot be applied to FILEA in LIBC. For the same reason, if you are referencing FILEA in LIBC on the Display Journal (DSPJRN), Receive Journal Entry (RCVJRNE), or Retrieve Journal Entry (RTVJRNE) commands, or on the Retrieve Journal Entries (QjoRetrieveJournalEntries) API, the entries for FILEA in LIBX are not returned.

To display or retrieve the journal entries of the original object, follow these steps:

  1. Save and then delete the existing object on the system.
  2. Restore the original object to the system.
  3. Display or retrieve the journal entries.
  4. Delete the original object.
  5. Restore the existing object back to the system.