Set up journaling - Connect_CDC - aws_mainframe_modernization_service - connect_cdc_mimix_share - Latest

AWS Mainframe Modernization - Data Replication for IBM i

Product type
Software
Portfolio
Integrate
Product family
Connect
Product
AWS Mainframe Modernization > AWS Mainframe Modernization Service
Version
Latest
Language
English
Product name
AWS Mainframe Modernization
Title
AWS Mainframe Modernization - Data Replication for IBM i
Copyright
2024
First publish date
2003
Last updated
2024-02-01
Published on
2024-02-01T23:02:31.099696

One or more database tables can be journaled to each environment, and multiple journal environments can exist at the same time on an individual IBM i machines.

Note: Connect CDC supports remote journals. Some changes are required on the i5 server where the remote journal resides and to Connect CDC Director.
Note: The Connect CDC Change Selector is not able to open and read journal records from a journal that has more than 2045 receivers. If this maximum is ever exceeded, then the Change Selector terminates with MSS CPF7053.

You must create or specify existing journals for:

  • All replication source tables

Source tables are journaled to provide the records of the data changes that Connect CDC captures for distribution to the target.

  • All replication and copy target tables

Target tables are journaled to provide transaction control for committing or rolling back a series of changes.

The tables must be journaled with before-images as well as after-images. In addition to providing control for committing or rolling back, before-images are required to detect distribution key changes and for data enhancement as well as for collision reporting in protected replication.

To create a journal, you must first define or have available one or more journal receivers and a journal message queue. The table below describes first the IBM i commands to create a receiver and a message queue, followed by the command to create a journal definition and to assign a table to the journal. The descriptions include usage comments and related commands.DB2/400 databases support logging of database transactions within a journal environment. The environment includes a journal definition (*JRN object), one or more journal receivers (*JRNRCV object), and a journal message queue (*MSGQ object).

Note: When creating a journal, the MINENTDTA parameter must be set to *NONE.
Table 1. IBM i Commands

Command

Comment

CRTJRNRCV

Creates a journal receiver (*JRNRCV object), the first of a series (chain) of physical storage containers for the journal.

You must create a receiver before you create the journal definition object. The receiver and journal may belong to different libraries.

Related commands:

  • DLTJRNRCV–Deletes a journal receiver.

  • DSPJRNRCVA–Displays journal receiver attributes.

CRTMSGQ

Creates a journal message queue (*MSGQ object), a persistent queue attached to the journal for receiving messages about the state of receivers.

You must create a message queue before you create the journal definition object.

It is not recommended to use the system message queue QSYSOPR for Connect CDC distribution. Its typical heavy usage makes it subject to operator maintenance that risks loss of data.

Related command:

DLTMSGQ–Deletes a journal message queue.

CRTJRN

Creates a journal definition (*JRN object), which contains management information for the journal environment and associates the receiver(s) and message queue with the journal.

It is recommended that you set the command option Manage receivers (MNGRCV) to *SYSTEM and set Delete receivers (DLTRCV) to *NO.

If this journal is for tables on a target-only Db2 for i server, journals are necessary for commitment control only, and Connect CDC change management is not available. You may want to specify *SYSTEM for Manage receivers and *YES for Delete receivers.

Changes to user data are recorded as entries in the journal receiver, each of which is identified by a sequence number. You can display the entries in the journal receiver by issuing the DSPJRN command.

Related commands:

  • DLTJRN–Deletes a journal definition object.

  • CHGJRN–Changes a journal definition object. For example, attaches a new receiver if receivers are user-managed and not system-managed.

  • WRKJRNA–Works with journal attributes, including the files that are journaled by the journal.

  • DSPJRN–Displays journal entries in detail.

  • DSPOBJAUT–Displays authorities.

  • GRTOBJAUT–Grants authorities to an object.

STRJRNPF

Starts journaling for a table (physical file) that is not currently being journaled.

Specify *BOTH for the Journal images option; this journals both before-images and after-images of the changed data. *BOTH is not the default.

Do not assign a table to the QAUDJRN journal (the system audit journal) in the QSYS library or to the Connect CDC metabase journal, if it exists.

Related command:

ENDJRNPF–Ends journaling on a physical file.