Previous Next

ZD&T Enterprise Edition - Installing Mainframe Emulator

We continue with the installation of IBM Z Development & Test Environment Enterprise Edition. ZD&T is based on the zPDT tool (IBM z Systems Personal Development Tool). In this entry, we are going to focus on installing the emulator used in the zPDT tool, which is the software that emulates the Mainframe.

 

The zPDT Redbook, which explains how to use the emulator, is the following:

 

Before having the emulator installed, we must install the license server. Check this post to do the installation:

This license server is needed to run the emulator and also to decrypt the *RES1.ZPD disks that come with the ADCD distributions. The decryption process "marks" these two disks with the license, to avoid sharing/selling them over the internet. In case it is shared or sold over the internet, the license and the associated customer could be identified.

 

As we said in the license server installation post, this emulator cannot be installed in the same machine as the web administration tool or the license server. For this reason, I have created a new virtual machine in VMware ESXi with Ubuntu Desktop 18.04.4.

 

Installing only the emulator is for those users who do not want to have the web tool. For example, they only want to have a system with an emulator installed. This option is more "fast", but it is more difficult to manage.

 

NOTE: Before starting the installation, make sure you have space to store the system disks. About 300GB for ADCD z/OS 2.4 November 2019 version. Also, make sure you have space for our user disks.

 

Before we start, we must meet these prerequisites (commands to install them in Ubuntu):

apt-get -y install iptables

dpkg --add-architecture i386

apt-get -y update

apt-get -y install libc6:i386 libncurses5:i386 libstdc++6:i386 lib32z1 lib32stdc++6

apt-get -y install ftp

apt-get -y install perl

apt-get -y install zip

apt-get -y install unzip

apt-get -y install gzip

apt-get -y install bc

apt-get -y install libasound2

apt-get -f install

apt-get dist-upgrade

 

To do the installation, we will follow these steps:

 

We copied the installation package to this machine. In my case, it's called ZDT_Install_EE_V12.0.5.0.tgz. We open a terminal and go to the path we copied it to.

Change the permissions to 775:

chmod 755 ZDT_Install_EE_V12.0.5.0.tgz

Decompress the file with the command:

tar -xzvf ZDT_Install_EE_V12.0.5.0.tgz

Run the program to do the installation:

./ZDT_Install_EE_V12.0.5.0.x86_64

001 watermark

 

The different options for installation will appear. In this case, we chose option 4 to install the emulator.

002 watermark

 

To install, 1 - Install.

003 watermark

 

After pressing enter (for a while...), if we agree with the license, we accept.
004 watermark

 

This option serves to share the IP of the Linux system (in this case, Ubuntu) with the z/OS. This way it is not necessary to give a new static IP to z/OS to be able to interact directly with the z/OS system.

To answer one thing or another, you will have to take into account your configuration, because if you do the automatic configuration, it will make changes to the Linux system, the Linux firewall and the TCPIP definition of z/OS.

In my case, I'll give Y, to test how it works.

005 watermark

 

We can also decide if we want to have the dependencies installed automatically. The system must be able to access the Internet. If we installed the prerequisites above, we can answer N.

006 watermark

 

The emulator will be installed. During the installation, the user ibmsys1 is created. We must change the password of this user using the command:

passwd ibmsys1

007 watermark

 

If we want to confirm that it is properly installed, we can use the command:

dpkg -l | grep z1091

008 watermark

 

Now let's change the configuration to indicate our license server that we installed in the previous post. To do this we go to the path /usr/z1090/bin and run the command:

./clientconfig

009 watermark

 

As a license server is software based, I will put the IP of the system where I installed the license server.

010 watermark

 

Once done (and with the license server running), we use the following command to check that it works:

NOTE: When I did it the first time, it did not connect to the license server because I put the license in later. With a system reboot where I am installing the zPDT emulator, it was fixed and showed the license information.

 

./query_license

011 watermark

 

Now let's create the instance (i.e. the configuration of disks and other resources to be booted) of the emulator. To do this, the first thing to do is to have the system disks that we will boot. In my case, the version I will use is ADCD z/OS 2.4 November 2019 edition.

First, we log in with the user ibmsys1 and save the disks in the path /home/ibmsys1/volumes

 

The *RES1.ZPD disks must be decrypted.

012 watermark

 

Now we have to make sure that the owner of all volumes is a non-root user (for example, ibmsys1). In addition to giving "755" permissions. We will use the commands:

chown ibmsys1 *

chgrp zpdt *

chmod 755 *

In my case, the owner and the group were fine, but the permits were not. In the image you can see the differences.

013 watermark

 

To decrypt the *RES1.ZPD volumes we will use the following commands:

cd /usr/z1090/bin

./Z1091_ADCD_install input_file output_file

For example:

./Z1091_ADCD_install /home/ibmsys1/volumes/A4RES1.ZPD /home/ibmsys1/volumes/A4RES1

./Z1091_ADCD_install /home/ibmsys1/volumes/SARES1.ZPD /home/ibmsys1/volumes/SARES1

When I executed the command, I got the following error:

error while loading shared libraries: libawsDiskItf.so

Apparently, this can be because I didn't use the user that is NOT root (ibmsys1), but I was using that user... I even created the ibmsys2 user, that was not root either, but the error was the same. I checked that this library existed in /usr/z1090/bin

014 watermark

 

At this point, I was a little lost (I even reinstalled Ubuntu and it didn't work), but I tried another program (the one that starts the emulator, awsstart) and I saw that it also gave an error when loading a different library, which, moreover, was in /usr/z1090/bin.

This made me think that the problem was in some environment variable that was not well defined. When I checked the hidden file ".bashrc" inside /home/ibmsys1, I saw that it tries to define some variables, but there must be some error in the file and it doesn't do it.

015 watermark

 

By using those commands by hand in a terminal with the user "ibmsys1", everything started working.

export PATH=/usr/z1090/bin:$PATH

export LD_LIBRARY_PATH=/usr/z1090/bin:$LD_LIBRARY_PATH

export MANPATH=/usr/z1090/man:$MANPATH

ulimit -c unlimited

ulimit -d unlimited

ulimit -m unlimited

ulimit -v unlimited

016 watermark

 

Even if this worked, the problem still existed, because when you reboot you had to give the commands again.

Investigating further, this happens because when the user is created, the "shell" that assigns it is /bin/sh, instead of /bin/bash.

You can check this with the command "getent passwd" and look for the user.

017 watermark

 

We can change it with the command:

chsh -s /bin/bash ibmsys1

018 watermark

 

019 watermark

 

With this changed, it is now possible to restart the system which will work properly. After this, I was able to extract the disks correctly.020 watermark

 

Now that we have all the volumes to use, let's create the "devmap". You can do it manually, but there is a script that does it directly. To run it:

cd /opt/ConfigGuideSample

perl create_devmap.pl volume_path > generateddevmap

For example:

perl create_devmap.pl /home/ibmsys1/volumes > generateddevmap

In my case, it failed because the net-tools package was missing. After installing it (apt-get install net-tools), it worked correctly.

021 watermark

 

The result is:

023 watermark

 

024 watermark

 

Now we will copy the files "generateddevmap" and "runzpdt" from the directory "/opt/ConfigGuideSample" to the directory where we have the volumes (/home/ibmsys1/volumes).

025 watermark

 

We start the emulator with the command:

./runzpdt -d <devmap name> -l <loadparm option>

For example:

./runzpdt -d generateddevmap -l cs

026 watermark

 

It wil start:

027 watermark

 

028 watermark

 

To reply, we will put:

oprmsg 'R 00,I'

029 watermark

 

To activate the console, we connect a 3270 terminal with the system IP and the port "3270". We use the commands:

oprmsg 'v cn(*),activate'

oprmsg 'v 700,console'

030 watermark

 

Surprisingly, this system won't start! When VTAM tries to boot, it will say that there is a module that is not in an APF library.

031 watermark

 

032 watermark

 

With the command "D PROG,APF", we see which libraries are authorized:

OPRMSG: LABEL:    FORMAT=DYNAMIC

OPRMSG: LABEL:    ENTRY VOLUME DSNAME

OPRMSG:       1  A4RES1 SYS1.LINKLIB

OPRMSG:       2  A4RES1 SYS1.SVCLIB

OPRMSG:       3  A4RES1 SYS1.SHASLNKE

OPRMSG:       4  A4RES1 SYS1.SIEAMIGE

OPRMSG:       5  A4RES1 SYS1.MIGLIB

OPRMSG:       6  A4RES1 SYS1.SERBLINK

OPRMSG:       7  A4RES1 SYS1.SIEALNKE

OPRMSG:       8  A4RES1 SYS1.CSSLIB

OPRMSG:       9  A4RES1 GIM.SGIMLMD0

OPRMSG:      10  A4RES1 SYS1.SHASMIG

OPRMSG:      11  A4RES2 CSF.SCSFMOD0

OPRMSG:      12  A4RES2 ISF.SISFLOAD

OPRMSG:      13  A4RES1 SYS1.SBDTCMD

OPRMSG:      14  A4RES1 SYS1.SBDTLIB

OPRMSG:      15  A4CFG1 USER.Z24A.LINKLIB

OPRMSG:      16  A4CFG1 FEU.Z24A.LINKLIB

OPRMSG:      17  A4SYS1 ADCD.Z24A.LINKLIB

OPRMSG:      18  A4CFG1 USER.Z24A.VTAMLIB

OPRMSG:      19  A4CFG1 FEU.Z24A.VTAMLIB

OPRMSG:      20  A4SYS1 ADCD.Z24A.VTAMLIB

OPRMSG:      21  A4RES1 FFST.SEPWMOD2

OPRMSG:      22  A4RES1 FFST.SEPWMOD4

OPRMSG:      23  A4RES2 NFS.NFSLIBE

OPRMSG:      24  A4RES1 TCPIP.SEZATCP

OPRMSG:      25  A4RES1 TCPIP.SEZALNK2

OPRMSG:      26  A4RES2 TCPIP.SEZADSIL

OPRMSG:      27  A4RES1 TCPIP.SEZALPA

OPRMSG:      28  A4RES1 TCPIP.SEZALOAD

OPRMSG:      29  A4RES1 ISP.SISPLOAD

OPRMSG:      30  A4RES1 SYS1.VTAMLIB

OPRMSG:      31  A4RES1 SYS1.SISTCLIB

OPRMSG:      32  A4RES2 CEE.SCEERUN

OPRMSG:      33  A4RES2 CEE.SCEERUN2

OPRMSG:      34  A4RES1 CBC.SCLBDLL

OPRMSG:      35  A4RES1 CBC.SCLBDLL2

OPRMSG:      36  A4PRD2 IGY630.SIGYCOMP

OPRMSG:      37  A4PRD1 EQAE10.SEQABMOD

OPRMSG:      38  A4PRD1 EQAE10.SEQAAUTH

OPRMSG:      39  A4PRD1 FAN140.SEAGLPA

OPRMSG:      40  A4PRD1 DIT130.SDITMOD1

OPRMSG:      41  A4PRD1 FELE10.SFEKAUTH

OPRMSG:      42  A4PRD1 FELE10.SFELLPA

OPRMSG:      43  A4PRD1 FEUC04.SFEUAUTH

OPRMSG:      44  A4PRD2 CSQ911.SCSQLINK

OPRMSG:      45  A4PRD2 CSQ911.SCSQAUTH

OPRMSG:      46  A4PRD2 CSQ911.CSQ9.SCSQAUTH

OPRMSG:      47  A4PRD2 CSQ911.SCSQSNLE

OPRMSG:      48  A4PRD2 CSQ911.SCSQANLE

OPRMSG:      49  A4PRD2 CSQ911.SCSQMVR1

 

The problem with this boot is that the VTAM task has the dataset "NET621.SCNMLNK1" in the VTAMLIB DD, but this dataset is not APF authorized, making none of that concatenation APF authorized.

To solve this and get the system started, we add the dataset to the APF list dynamically.

SETPROG APF,ADD,DSNAME=NET621.SCNMLNK1,VOLUME=A4PRD3

033 watermark

 

Now we can start VTAM. Command:

S VTAM

034 watermark

 

Now it will start properly.

035 watermark

 

We're waiting for it all to start.

036 watermark

 

We'll be able to access the system now.

037 watermark

 

Now we take the opportunity to fix the error in the corresponding library.

We confirm that the NET621.SCNMLNK1 library is in the concatenation of the VTAMLIB DD.

038 watermark

 

To know the PROGxx member in which we must add the dataset, we can do the following:

Check the LOADCS member (because we start with the CS loadparm) and check the SYSPARM parameter, which refers to the IEASYS member, in this case, IEASYSCS.

039 watermark

 

Check the PROG parameter of the IEASYSCS member.040 watermark

 

Add the library to the PROGAB member. It is already defined for future IPLs.

041 watermark

 

To stop the emulator, we will use the "shutdown" commands that exist in these systems (that they exist here does not mean that they are in other "real" systems).

In my case, as I have started with the LOADPARM "CS", I will stop with the "S SHUTDOWN" command.

Another command to stop is the "S SHUTALL". There are more available, but I mainly use those two.

Once I have stopped everything, after the "$PJES2" command, we will do the "QUIESCE" command in the z/OS console. This is a way to stop the processors.

Then in the emulator terminal (in Ubuntu), we will give the command "awsstop" to stop the emulator.

042 watermark

 

Optionally, we can install the x3270 terminal and configure the emulator startup to have the console in this terminal.

 

To install x3270:

apt-get install x3270

043 watermark

 

Then, this command must be added to the Devmap file:

command 2 x3270 -model 3 localhost:3270

NOTE: "model 3" is a 32-line terminal and "model 4" is 43. We must use whatever port we have configured.

This way, when we start the emulator, it will start the terminal and we will have the console.

044 watermark

 

We've already checked that it works properly. In the next entry we will install the web utility and learn how to use it.

 

 

 

View Javier Fernández García's profile on LinkedIn

LINKEDIN

 

View Javier Fernández García's profile on Acclaim

ACCLAIM

 

dinoland site logo

DINOLAND

Search

© 2015-2020 EMUFRAME