Installing Natural for Db2 for zIIP Version 9.2.3 on z/OS

#### Search Results

Search

# Installing Natural for Db2 for zIIP Version 9.2.3 on z/OS

This document describes the additional steps for installing Natural for Db2 for zIIP Version 9.2.3 (product code NDZ) on z/OS.

- Installation Medium

- Prerequisites

- Installation Procedure

- NDZ Server Installation Steps

- Add NDZ Support to Natural Batch Nucleus

#### Related Topics:

For information on how to use Natural for Db2 for zIIP, see Natural for Db2 for zIIP in the Database Management System Interfaces documentation.

#### Notation vrs or vr:

When used in this document, the notation `vrs` or `vr` represents the relevant product version (see also Version in the Glossary).

## Installation Medium

The installation medium contains the following datasets required for product installation:

Data Set Name | Contents
--- | ---
`NDZvrs.LOAD` | Load modules
`NDZvrs.JOBS` | Sample jobs for static preparation, creating trusted context, etc.
`NDZvrs.TAR` | USS files (tar format for extraction to unix system services)

Copy the datasets into your environment as described in Copying Data Sets to a z/OS Disk in the section Installing Natural.

## Prerequisites

Before you can install Natural for Db2 for zIIP, you must have a complete and functioning installation of the standard Natural for Db2 (product code ‘NDB’) in the Mainframe environment, see Natural for Mainframes > Installation for z/OS > Installing Natural for Db2 on z/OS.

Parts of Natural for Db2 for zIIP will be installed in the Unix Systems Services environment (USS), and USS must have the following configuration and software already installed:

IBM Java 64-bit This is an example of how to verify the java installation and version (your Java version may be different). |
    $ <JAVA_PATH>/bin/java –version

    java 17.0.7 2023-04-18
    IBM Semeru Runtime Certified Edition for z/OS 17.0.7.0 (build 17.0.7+7)
    IBM J9 VM 17.0.7.0 (build z/OS-Release-17.0.7.0-b01, JRE 17 z/OS
    s390x-64-Bit Compressed References 20230809_41 (JIT enabled, AOT enabled)
    OpenJ9   - bc2691d03c1
    OMR      - 49ecb822254
    IBM      - fae32e3
    JCL      - 8e3170b6410 based on jdk-17.0.7+7)
Db2 JDBC Driver This is an example of how to verify the JDBC driver installation and version (your driver version may be different). |
    $ <JAVA_PATH>/bin/java -cp <DB2_PATH>/jdbc/classes/db2jcc.jar
    com.ibm.db2.jcc.DB2Jcc  -version

    IBM DB2 JDBC Universal Driver Architecture 3.72.54
NDZ Installation Directory An installation directory for NDZ must already have been created. |
    $ pwd
    /DAXY/u/nat/ndzuser
    $ mkdir ndz923

In addition, the following must be configured on z/OS:

- The NDZ load library must be included in the APF authorized list.

- RACF user (called ndzuser in the the following examples) with:

  - A started RACF profile defined for NDZ started task(s).

  - A permit to `ERBSDS.MON3DATA` RACF facility profile.

  - A permit to `BPX.WLMSERVER` RACF facility profile.

  - Write permissions to the NDZ installation directory.

- A Db2 user (called db2user in the following examples) must be created to access Db2 via TCP/IP. ndzuser can also be used in place of db2user.

## Installation Procedure

Be sure to read Installation Process and Major Natural Features on z/OS before you start the installation procedure.

The installation procedure comprises the following:

- NDZ Server Installation Steps

- Installation Steps Specific to Batch

## NDZ Server Installation Steps

This section describes the installation steps that apply to all Natural environments where Natural for Db2 for zIIP can be installed.

- Step 1: Prepare the License Key

- Step 2: Create Trusted Context

- Step 3: Copy and Extract the NDZ Installation TAR file

- Step 4: Generate the db2.properties File

- Step 5: Generate the ndz.properties File

- Step 6: Update Static Preparation Shell Script setenv.sh

- Step 7: Encrypt the Db2 Password (optional step)

- Step 8: Link the NDZ Nucleus

- Step 9: Create NDZ started task procedure(s)

### Step 1: Prepare the License Key

Copy the license file from the supplied installation medium to disk. If the license file is supplied on PC as an .xml file, then allocate a dataset called NDZvrs.LICS with the attributes below:

    ORGANIZATION   :  PS
    RECORD FORMAT  :  FB
    RECORD LENGTH  :  80
    BLOCK SIZE     :  27920
    ALLOCATION TYPE:  TRK
    1ST EXTENT     :  0       CYL 1   TRK

Then use FTP in binary transfer mode to transfer the .xml file from the PC to the dataset.

### Step 2: Create Trusted Context

(Job I010 Step 9610)

Create the Trusted context object in a Db2 server using the Db2 user to establish a trusted connection.

- Replace the variable ‘UID’ with db2user. For example:

      BASED UPON CONNECTION USING SYSTEM AUTHID db2user

- Submit the job.

### Step 3: Copy and Extract the NDZ Installation TAR file

(Job I020 Step 9610 + 9615 + 9620)

- Step 9610 (delete old .tar and Java jar files in USS, if present)

- Step 9615 (copy .tar file to USS)

- Step 9620 (unpack .tar file in USS)

- Edit NDZvrs.MVSJOBS(NDZI020) and replace all occurrences of /U/SAG/NAT/NDZ with your actual installation directory.

- Submit the job.

### Step 4: Generate the db2.properties File

(Job I022 Step 9615)

Create the Db2 properties file in the NDZ configuration directory (`<NDZ installation directory>/etc/db2.properties`) with the specific Db2 connection and configuration properties.

#### OR:

1. Create the `<NDZ installation directory>/etc/db2.properties` file from the sample file `<NDZ installation directory>/etc/db2.properties.sample`.

2. Set the variables according to the instructions located in the sample file.

For more information, refer to Natural for Mainframes > Database Management System Interfaces > Configuration and Parameters > Parameters.

### Step 5: Generate the ndz.properties File

(Job I022 Step 9620)

Create the NDZ properties file in the NDZ configuration directory (`<NDZ installation directory>/etc/ndz.properties`) with the parameters for the NDZ Server.

#### OR:

1. Create the `<NDZ installation directory>/etc/ndz.properties` file from the sample file `<NDZ installation directory>/etc/ndz.properties.sample`.

2. Set the variables according to the instructions located in the sample file.

For more information, refer to Natural for Mainframes > Database Management System Interfaces > Configuration and Parameters > Parameters.

### Step 6: Update Static Preparation Shell Script setenv.sh

(Job I022 Step 9625)

Update the shell script responsible for setting the Db2, Java, and NDZ home path variables (`<NDZ installation directory>/bin/setenv.sh`) for the NDZ Server.

#### OR:

Create the `<NDZ installation directory>/bin/setenv.sh` file from the sample `<NDZ installation directory>/bin/setenv.sh.sample` file. Update the Db2, Java, and NDZ home path variables in the setenv.sh file.

For more information, refer to Natural for Mainframes > Database Management System Interfaces > Configuration and Parameters > Parameters.

### Step 7: Encrypt the Db2 Password (optional step)

You may secure your Db2 connection password using Db2 password encryption. Doing so is optional but strongly recommended. The instructions are described in Database Management System Interfaces > Configuration and Parameters > Db2 Password Encryption.

If you use the Db2 encrypted password utility, you may delete the password parameter from the db2.properties file, as this parameter will be ignored.

### Step 8: Link the NDZ Nucleus

(Job I058 Step 9610)

Link the NDZ nucleus with `NDZvrs.LOAD`(`NDZNUC`), `MLCvrs.LOAD`(`LICMAIN`) and `MLCvrs.LOAD`(`LICCHECK`).

### Step 9: Create NDZ started task procedure(s)

(Job I200 Step 9610)

Create procedure(s) for NDZ started task(s) (or daemons) using the following template:

    //NAME   PROC
    //*
    //NDZ11    EXEC  PGM=NDZNUC11,REGION=0M,TIME=NOLIMIT,
    //  PARM=('PATH=<NDZ INSTALLATION DIRECTORY>','PORT=<PORT NUMBER TO CONNECT TO>')
    //*--------------------------------------------------------------------*
    //LICNDZBT DD DISP=SHR,DSN=<LICENSE DATASET>
    //STEPLIB  DD DISP=SHR,DSN=<LOAD DATASET>
    //SYSPRINT DD SYSOUT=X
    //SYSOUT   DD SYSOUT=X
    //SYSUDUMP DD SYSOUT=X
    //STDOUT   DD SYSOUT=X
    //STDERR   DD SYSOUT=X

- Substitute the highlighted parts using the following instructions:

  - `NAME` – The name of the started task.

  - `NDZ INSTALLATION PATH` – The path to the NDZ home directory.

  - `PORT NUMBER TO CONNECT` – The port number.

  - `LICENSE DATASET` – The dataset which contains the license file.

  - `LOAD DATASET` – The APF authorized dataset in which the NDZ nucleus is located.

- Submit the job.

## Add NDZ Support to Natural Batch Nucleus

(Job I060 Step 9625)

1. Link the Batch Nucleus with NDZ Support.

2. Add the following `INCLUDE` statements and corresponding `DD` statements to the link instructions for the linkage editor. Specify the same Db2 interface module used during NDB installation, see Natural for Mainframes > Installation for z/OS > Installing Natural for Db2 on z/OS.

   `INCLUDE NDBLIB(NDBNDZ)` | NDB support for NDZ
   `CHANGE DSNHLI(DB2HLI)` | Db2 Interface module
   `INCLUDE DB2LIB(DSNALI)` OR `INCLUDE DB2LIB(DSNELI)` | Db2 Interface module (CAF) Db2 Interface module (TSO)

### On this page

- Installation Medium
- Prerequisites
- Installation Procedure
- NDZ Server Installation Steps
- Add NDZ Support to Natural Batch Nucleus