C H A P T E R 5 |
Verifying the Installation |
A set of sample programs comes with the Sun MTP software. Running one of these programs verifies that you have properly installed the software. This chapter describes how to use the sample programs. It contains the following topics:
The $UNIKIX/test directory contains the sample applications for COBOL, C, and relational databases.
If you are using Liant Open PL/I, the sample application is located in the $LPI_PRODUCT_DIR/examples/OpenPLI/kix directory. See Running the PL/I Sample Application.
Before you can run the sample application, you must:
|
1. Log in as the user who installed Sun MTP, not as root.
2. Execute the env command to verify that the UNIKIX, KIXLICDIR, COBDIR, LD_LIBRARY_PATH, and PATH environment variables are set.
If they are not set, source the setup file you created in Creating the Sun MTP Setup File.
3. Verify that the TERM environment variable reflects the terminal type you are using.
4. Execute the kixprimer setup script to set the Primer region's environment variables.
kixprimer sets the $KIXSYS, $KIXPROGS, $KIXMAPS, $KIXDATA, and $KIXLIB environment variables to the directory $UNIKIX/test/primer/cobol.
5. Sun MTP provides a compiled version of the ACCT application for the VSAM environment.
a. Change to the $KIXSYS directory, if you are not already there:
b. Execute the build_ACCT.sh shell script to compile the programs:
|
1. Start the region by typing kixstart at a command prompt.
For more information about starting Sun MTP, refer to the Sun Mainframe Transaction Processing Software Configuration Guide.
2. Make a local client connection using the unikix command.
For example, if you are using an X terminal with a 101-key keyboard, type:
Refer to the Sun Mainframe Transaction Processing Software Configuration Guide for more information about connecting to Sun MTP.
3. Press any key to clear the Sun MTP copyright screen.
4. Type ACCT in the upper left corner of a blank transaction screen and press the Enter key (not the Return key).
The transaction is executed and the screen in FIGURE 5-1 is displayed.
5. Type GREENFIELD in the SURNAME field and press the Enter key.
A list of records that match the surname value is displayed.
6. Clear the screen by pressing the Clear key.
Type the following transaction in the upper left corner of the screen and press Enter.
The directory $UNIKIX/test/primer/C contains the C sample application. Refer to the Sun Mainframe Transaction Processing Software Developer's Guide for more information about using C programs.
|
1. Make sure that a compatible C compiler is installed.
2. Log in as the user who installed Sun MTP, not as root.
3. Execute the env command to verify that the UNIKIX, KIXLICDIR, LD_LIBRARY_PATH, and PATH environment variables are set.
If they are not set, source the setup file you created in Creating the Sun MTP Setup File.
4. Verify that the TERM environment variable reflects the terminal type you are using.
5. Execute the kixprimer setup script to set the other variables.
kixprimer sets the KIXSYS, KIXPROGS, KIXMAPS, and KIXDATA environment variables to the directory $UNIKIX/test/primer/C.
6. There is a compiled version of the ACCT application for the VSAM environment.
a. Change to the $KIXSYS directory if you are not already there:
b. Execute the build_ACCT.sh shell script to compile the programs:
|
1. Start the region and make a local connection.
See Running the COBOL Sample Application.
2. Close the Sun MTP copyright screen by pressing any key.
3. Type the ACCT transaction on a blank transaction screen and press Enter.
4. When the sample application screen is displayed, type GREENFIELD in the SURNAME field and press Enter.
5. Sun MTP should display a list of records matching the surname value.
6. Press the Clear key to clear the screen.
7. Shut down the region using the CSMT SHUT,YES transaction.
After installing PL/I, the account application is located in the $LPI_PRODUCT_DIR/examples/OpenPLI/kix directory. The following table shows the directory's contents. The PROJECT environment variable used in the procedure To Set Up the PL/I Primer Region points to this directory.
Before running the PL/I sample application, you must:
|
1. Change to the directory where the setup scripts are located:
2. Set the environment variables, making sure to set $LD_LIBRARY_PATH.
4. If you have not already done so, change to the $UNIKIX/src directory and run kixinstall to select the Liant Open PL/I language option.
This creates a makefile in the $UNIKIX/src directory. When executed, this makefile will create the new transaction server in the $UNIKIX/local/bin directory.
5. Make a backup copy of the makefile:
6. If you want to change the location of the transaction server, edit $PROJECT/bin/makefile and change BINDIR=${UNIKIX}/local/bin to another value, such as BINDIR=${KIXBIN}
7. Change directory to $UNIKIX/src and run make to build the sample application, the maps, and a new transaction server.
An illustration of the makefile used in this procedure is shown in the Sun Mainframe Transaction Processing Software Developer's Guide.
After the modules are built, the bin and lib subdirectories contain the files listed in the following table.
|
1. Start the region and a local client from an Xterm:
2. Close the Sun MTP copyright screen by pressing any key.
3. Type the ACCT transaction on a blank transaction screen and press Enter.
4. When the sample application screen is displayed, type GREENFIELD in the SURNAME field and press Enter.
5. Sun MTP should display a list of records matching the surname value.
6. Press the Clear key to clear the screen.
7. Shut down the region with the CSMT SHUT,YES transaction.
Copyright © 2004, Sun Microsystems, Inc. All rights reserved.