Prerequisites
The following section describes the prerequisites for working with the Qlik Replicate IBM DB2 for z/OS endpoint.
Install the R4Z product on z/OS
Before you can work with an IBM DB2 for z/OS source, you must first download, install and configure the R4Z component on z/OS. R4Z is available for download from Qlik Community.
To download R4Z:
-
Go to the Qlik Download Site.
-
Select Qlik Data Integration.
-
Scroll down the Product list and select Replicate.
-
In the Download Link column, locate the QlikReplicate_<version>_r4z file. Before starting the download, check the Version column to make sure that the version correlates with the Replicate version you have installed.
-
Download R4Z and install it on your z/OS data source.
For installation, and configuration instructions, seeInstalling and configuring R4Z .
Client requirements
The IBM Data Server Driver for ODBC is required in order to access the data. This section describes the client side and server side ODBC prerequisites.
The "enableWLB" driver option is not supported. To force the connection to automatically switch to another LPAR in a parallel sysplex (i.e. “failover”), set “enableACR” to “true” and “enableWLB” to “false” in the driver configuration.
Windows
Install "IBM Data Server Driver for ODBC and CLI" for DB2 11.5.6 for z/OS on the Qlik Replicate Server machine.
Linux
-
Stop the Replicate service:
./areplicate stop
-
Optionally, confirm that the service has stopped:
./areplicate status
- Install v11.5.6_linuxx64_server_dec.tar.gz and choose the “CLIENT” option.
-
If the Replicate machine does not have a DB2 instance, create a DB2 instance by running the following commands:
adduser <db2_instance_name>
/opt/ibm/db2/V11.5/instance/db2icrt <db2_instance_name>
-
Change the working directory to <Replicate_Install_Dir>/bin.
-
Add the DB2 driver location to the Linux library path.
To do this, add the following line to the site_ arep_login.sh file as follows:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/path/lib
where path is the CLIENT path to the driver.
Example (with db2clnt1 as the instance name):
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/db2clnt1/sqllib/lib:/home/db2clnt1/sqllib/lib64/gskit
export DB2INSTANCE=db2clnt1
-
Optionally, confirm that the driver location was copied:
cat site_arep_login.sh
-
Add the following entry to the odbcinst.ini file under /etc:
[IBM DB2 ODBC DRIVER]
Driver = /home/db2clnt1/sqllib/lib/libdb2o.so
fileusage=1
dontdlclose=1
-
Start the Replicate service:
./areplicate start
-
Optionally, confirm that the service has started:
./areplicate status
Server side ODBC setup
Bind the plan to be used for ODBC, as specified in the PLANNAME= value in the ODBC initialization file. The default name is DSNACLI. The BIND job can be found in member DSNTIJCL, which is in the SDSNSAMP library of the source DB2 installation.
Use the DB2CLI bind command to bind the ODBC-supplied packages to your intended source z/OS DB2 subsystem. This action is described in Configuring your developer and runtime environment on the IBM website. For information about the DB2CLI utility, including an example for the bind utility, see db2cli - DB2 interactive CLI command on the IBM website.
Required permissions
To enable Replicate to extract data from the source tables (Full Load and Change Data Capture), the user specified in the IBM DB2 for z/OS endpoint settings must be granted the following permissions:
- EXECUTE on the IFI reading the UDTF (only required for Change Data Capture)
- SELECT on the source tables and on the following system catalog tables:
- SYSIBM.SYSDUMMY1
- SYSIBM.SYSTABLES
- SYSIBM.SYSTABLESPACE
- SYSIBM.SYSPARMS
- SYSIBM.SYSROUTINES
- SYSIBM.SYSCOLUMNS
- SYSIBM.SYSLGRNX
- SYSIBM.SYSTABLEPART
- MONITOR2 to be able to start IFI sessions (only required for Change Data Capture)
For additional details about these permissions, see Change Data Capture Requirements below.
Change data capture requirements
To capture changes from IBM DB2 for z/OS, Replicate uses a special program - invoked as an external routine - which is a user-defined table function (UDTF). Both this program (a load module) and the UDTF need to be installed and configured on the z/OS system before changes can be captured. The installation procedure, which should be performed by the DBA, is described in see Installing and configuring R4Z.
Additionally, the DATA CAPTURE CHANGES attribute must be set for every table whose changes you want to capture. You can either do this manually or allow Replicate to do this by leaving the Automatically enable DATA CAPTURE CHANGES (requires admin privilege) option enabled (the default) in the endpoint settings.