This section describes how to configure a client workstation to communicate
with a DB2 server using the APPC communication protocol, and assumes that APPC
is functional on the client and DB2 server workstations. See Software Requirements for the communication protocol requirements for your
platform. See Possible Client-to-Server Connectivity Scenarios for the supported communication protocols for your
particular client and server.
![]() |
You need to ensure that the DB2 server that you are attempting to establish communications with supports APPC clients. APPC client communications are supported by the following DB2 servers:
For more information, see Software Requirements.
|
The following steps are required to set up a client to use APPC communications:
As you proceed through the configuration steps, complete the
Your Value column in the following table. You can fill in
some of the values before you start configuring this protocol.
Table 19. APPC Values Required at the DB2 Client
| Parameter | Description | Sample Value | Your Value |
|---|---|---|---|
| Symbolic destination name (sym_dest_name) |
Specifies the name of the CPI-C profile defined in APPC on the client. This profile contains information that allows the client to communicate with the server. This profile name is used by DB2 as a link into the APPC communications
subsystem on your client. Obtain this name from your APPC System
Administrator or your APPC management tools.
| NYSERVER | |
| Security type (security_type) | Specifies the type of APPC security to be used for the connection. It is recommended that you use the security level none for the APPC connection. If you do not specify this parameter in B. Catalog the APPC Node, the default program is used. | none |
|
| Node name (node_name) |
A local alias, or nickname, that describes the node where the database
resides. You can choose any name you want, however, all node name
values within your local node directory must be unique.
| db2node |
The following steps describe how to configure this protocol on the client. Replace the sample values with your worksheet values.
You must update the APPC communication profiles before your
client can access a DB2 server. Use the provided worksheet to help you
track values when updating the APPC profiles for your particular
client.
Table 20. APPC Values Required at the Client
| No. | Description | Sample Value | Your Value | ||
|---|---|---|---|---|---|
| Network Connection Information at the DB2 Client | |||||
| (13) | Partner node name | NYX1 |
| ||
| (14) | Type | Token-ring |
| ||
| (15) | Connection name | LINKNYX1 |
| ||
| (16) | LAN Destination Address | 40005AA8B532 |
| ||
| (17) | Partner network ID | SPIFNET |
| ||
| (18) | Partner LU name | NYX1GW01 |
| ||
| Network Elements at the DB2 Client | |||||
| (19) | Network name | SPIFNET |
| ||
| (20) | Local node name (same as the Control Point name) | NYX2 |
| ||
| (21) | Local node ID | 05D27510 |
| ||
| (22) | Partner LU fully-qualified LU name | SPIFNET.NYX1GW01 |
| ||
| (23) | Symbolic destination name | NYSERVER |
| ||
| (24) | Partner TP name | NYSERVER |
| ||
| (25) | Security type | NONE |
| ||
| (26) | Mode name | IBMRDB |
| ||
| (27) | Local LU name | NYX2GW01 |
| ||
| |||||
![]() |
Go to the section that describes that required steps to update the APPC profiles for the client that you want to use to communicate with you DB2 server.
|
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
Samples of the profiles are provided. A field that has been changed with the default value has been marked with a number in parentheses in each of the sample profiles.
A worksheet is provided on Table 20. Each of the values marked with numbers in parentheses in the following samples are included in the corresponding worksheet. Use the worksheets to record the values of parameters that you need to provide when you create or modify a profile.
Configure your DB2 Connect system as follows:
smit
The next several steps begin from the Advanced Configuration panel.
The control point name was probably set when the SNA Server for AIX was installed. (20).
To minimize confusion, use the same value for the control point alias as for the control point name.
For example, the panel could look like this:
Change / Show Control Point Profile *Profile name node_cp XID node ID [05D27510] (21) Network name [SPIFNET] (19) Control Point (CP) name [NYX] (20) Control Point alias [NYX2] (20) Control Point type appn_end_node Maximum number of cached routing trees [500] Maximum number of nodes in the TRS database[500] Route addition resistance [128]
Write down the profile name.
For example, the profile might look like this:
Add Token Ring SNA DLC Profile
*Profile name [tok0.00001]
Data link device name [tok0]
Force disconnect time-out (1-600 seconds) [120]
User-defined maximum I-Field size? no
If yes, Max. I-Field size (265-30729) [30729]
Dynamic link stations supported? yes
*Profile name [IBMRDB] (26) Mode name [IBMRDB] (26) Maximum number of sessions (1-5000) [30] (*) Minimum contention winners (0-5000) [15] (*) Minimum contention losers (0-5000) [15] (*) Auto activate limit (0-500) [0] Upper bound for adaptive receive pacing window [16] Receive pacing window (0-63) [8] (*) Maximum RU size (128,...,32768: multiples of 32) [4096] (*) Minimum RU size (128,...,32768: multiples of 32) [1024] (*) Class of Service (COS) name [#CONNECT]
Add LU 6.2 Local LU Profile
*Profile name [NYX1GW02] (27)
Local LU name [NYX1GW02] (27)
Local LU alias [NYX1GW02] (27)
Local LU is dependent? no
If yes,
Local LU address (1-255) []
System services control point
(SSCP) ID (*, 0-65535) [*]
Link Station Profile name []
Conversation Security Access List Profile name []
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
To use APPC, SNAplus must be installed and configured on the client workstation, and you must create an entry in the node directory.
This section will give you an example of how to use those values to configure the SNA parameters on the DB2 Client Application Enabler for HP-UX workstation. This is only an example; you should be familiar with SNA and your own communications configuration to successfully configure SNAplus for DB2 Client Application Enabler for HP-UX.
Refer to the HP-UX SNAplus Installation Guide, the HP-UX SNAplusLink Administrator's Guide, the HP-UX SNAplus API Administrator's Guide, and the HP-UX SNAplusLink Diagnostics Guide for more information about:
Notes:
The names and addresses in this example are:
CP Name NYX2 (20) Remote LINK ADDRESS 40005AA8B532 (16) XID Node ID 05D27510 (21) Network Name SPIFNET (19) Local LU Name NYX2GW01 (27) Remote LU Name NYX1GW01 (18) Remote Transaction Program Name NYSERVER (24) Mode Name IBMRDB (26)
To configure SNAplus for DB2 Connect, log on as root and use either the /opt/sna/bin/snapconfig program or the /opt/sna/bin/X11/xsnapconfig program. Information about these programs can be found in the HP-UX documentation. The following steps describe how to use these programs to configure SNAplus for DB2 Connect.
| Note: | These steps contain suggested values for configuration parameters. For other parameters, use the SNAplus default values. |
For Token Ring links, use the default Device Name and Port Number. For SDLC and QLLC links, consult with your network administrator for the appropriate values. When you have filled in the information, or chosen to use the default values, click on OK followed by Done to get back to the main screen.
Other values can be left as defaults.
Notes:
Use /opt/sna/bin/snapstart to start the SNAplus subsystem. You can use /opt/sna/bin/snapstop to stop the SNAplus subsystem first, if required.
To start the SNAplus connections you can use either the /opt/sna/bin/snapmanage program, or the /opt/sna/bin/X11/xsnapmanage program.
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
Begin to configure your DB2 Connect system with the following steps:
If this is a new configuration file, the next panel displayed will be the APPC APIs over Token-Ring panel. Otherwise the next panel displayed will be the Communications Server Profile List panel.
![]() |
You can select either the End node - to a network node server
radio button or the End node - no network node server radio
button. A network node server is used when many users are routed
through the same connection. The example here presumes no network node
server is used.
|

Subsequent steps begin from this panel. You will return to this panel when each step is complete.
From the Communications Server Profile List panel, prepare a LAN DLC profile as follows:
Update SNA Local Node Characteristics as follows:
![]() |
The first part should be filled in for you already when you display the
profile. You only need to complete the second part.
|
Prepare the SNA connection profiles as follows:
The Connection to a Peer Node or Connection to a Host Node windows opens. At the Connection to a Peer Node panel or the Connection to Host panel:
Create a Partner LUs Profile as follows:
From the SNA Features List panel, prepare a Mode Definition as follows:
On the SNA Features List panel, select CPI Communications Side Information->Create. The CPI Communications Side Information opens.
Complete the CPI Communications Side Information panel as follows:
Select the None radio button as the Security
type.
![]() |
This does not mean that you will have no security, you will specify the
security type later when you update the DB2 directories.
|
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
The following section provides a working example of the SNA configuration on a DB2 for SINIX client to support communications with a server workstation.
Notes:
There is one configuration file that is read by the TRANSIT Server on startup. This configuration file has a default name of /opt/lib/transit/KOGS/conf.nuc. The configuration file defines the SNA resources and operating characteristics through a set of configuration directives.
The following example is a configuration file that contains the configuration directives.
XLINK tok0.001, //Link name
ACT = AUTO, //Activation
TYP = LAN, //Connection type
XID = 05D27946, //Node ID
CPNAME = CAIBMOML.OMXTXL, //Control point
CONFSTR = /opt/lib/llc2/conf.str, //Confstr
DEVICE = tr0, //Device
SSAP = 04 //SSAP
XPU JAGUAR, //Station name
TYP = PEER, //Type
CONNECT = AUTO, //Connection setup
DISCNT = AUTO, //Connection shutdown
LINK = tok0.001, //Link name
NVSCONNECT = DYNAMIC, //NVS connect
MAXDATA = 265, //Segment size
XID = 05D27946, //Node ID
CPNAME = CAIBMOML.OMXTP909, //Control point
ROLE = NEG, //Station role
PAUSE = 3, //Pause
RETRIES = 10, //Retries
DMAC = 10005AA8E208, //DMAC
DSAP = 04, //DSAP
RWINDOW = 7 //Window
XLU OMXTXL, //Name
TYP = 6, //LU type
PUCONNECT = APHSTART, //Connection
CTYP = PUBLIC, //Coordinate Type
SESS-LMT = 3, //Session limit
SESS-CTR = IND, //Session control
NETNAME = CAIBMOML.OMXTXL, //Network name
PAIR = OMXTP909 IBMRDB //LU pair
XRLU OMXTP909, //Remote LU name
NETNAME = CAIBMOML.OMXTP909, //Network name
PU = JAGUAR //Station name
XMODE IBMRDB, //Mode name
SESS-MAX = 20, //Session Max
SESS-LOS = 10, //Session Loser
SESS-WIN = 10, //Session Winner
SESS-AUTO = 5, //Session Auto
SRU-MAX = 87, //RU size Send
RRU-MAX = 87, //RU size Recv
PAC-SEND = 4, //Pacing Send
PAC-RCV = 4, //Pacing Recv
IDLETIME = 0 //Idle time
XSYMDEST CPICSND, //SD name
RLU = OMXTP909, //RLU name
MODE = IBMRDB, //Mode name
TP = CPICRCV, //TP name
TP-TYP = USER, //Type
SEC-TYP = NONE //Security
XEND
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
You also have to create a file containing the CPI-C side information representing the Symbolic Destination Name.
You can use or your favorite editor to create the configuration files.
This file must be placed in the application's path for a standalone DB2 Connect for Solaris system. However, for DB2 agents to be able to access it on DB2 Connect for Solaris, the file should be in either:
| Note: | The name of the CPIC side file must be the same as the Symbolic destination name specified in the DB2 node directory on the DB2 Connect for Solaris system. |
Sample CPIC side file
The file name must be the same as the Symbolic destination name specified in the DB2 node directory for the server.
# CPIC Side File information # PTNR_LU_NAME=NYX1GN01 MODE_NAME=IBMRDB TP_NAME= NYSERVER SECURITY=NONE
This file is called sunpu2.config, and it must be placed in /opt/SUNWpu21, or the directory where SunLink SNA PU 2.1 Server is installed.
Figure 1. Sample Solaris PU 2.1 SNA Client Configuration File
// SunLink SunLU6.2/SunPU2.1 SNA Server Sample Configuration
// Token Ring Peer-to-Peer System A @(#)sunlu62.a.tr
//
// The physical connection is a Token Ring interface adapter.
CP NAME=NYX2 // Local name (8 char max)
NQ_CP_NAME=SPIFNET.NYX12 // Network Qualified Name
;
TRLINE NAME=MAC1 // SunLink specific name
SOURCE_ADDRESS=x'400011527509' // sysA_mac_addr for Sun machine
;
DLC NAME=HOSTLINK // User defined name (8 char max)
LINK_NAME=MAC1 // Line name this station is on
LCLLSAP=x'04' // Local Link Service Access Point
RMTLSAP=x'04' // Remove Link Service Access Point
RMTMACADDR=x'40005AA8B532' // sysB_mac_addr
TERMID=x'07127509' // XID negotiation
;
LU NAME=NYX2GW01 // Local name (8 char max)
NQ_LU_NAME=SPIFNET.NYX2GW01 // Network Qualified Name
SESS_LMT=50 // Max LU sessions
LUTYPE=6.2
;
PTNR_LU NAME=NYM2DB2 // Partner LU name(8 char max)
LOC_LU_NAME=NYX1GW01 // Associated Local LU
NQ_LU_NAME=SPIFNET.NYM2DB2 // Network Qualified Name
;
MODE NAME=IBMRDB // Mode Name (8 char max)
DLC_NAME=HOSTLINK // Associated DLC
PTNR_LU_NAME= // Associated Partner LU
LCL_MAX_SESS_LMT=30 // Max Session Limit
MIN_CW_SESS=15 // Min Conwinners
MIN_CL_SESS=15 // Min Conlosers
;
|
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You may need to create an entirely new configuration file or customize an existing one. This section assumes that you are creating a new configuration file, but if you are customizing an existing one the steps are similar. You need to perform the following configuration steps:
To begin, perform the following steps:
To configure the node, do the following (this example is for an End Node):
To configure devices, do the following (this example used a LAN DLC):
To configure the LAN connection, do the following:
No action is required.
To configure the partner LU, do the following:
To configure the mode, do the following:
To configure the local LU, do the following:
To configure the CPI-C Side Information, do the following:
Click the radio button that selects which of these you will use. Either specify the fully-qualified partner LU name SPIFNET.NYX1GW01 (the same value as worksheet item (22)), or select the Partner LU alias that you defined earlier (the same value as worksheet item (18) in this example).
To complete the configuration file, from the Communications Server SNA Node Configuration window:
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You need to customize the APPC configuration for the client. The following list gives the APPC profiles that you will need to update on your client workstation before you can access a DB2 server using APPC.
To begin, perform the following steps:
![]() |
By default, the Servers and Connections window opens. If it does
not, double-click on the Servers and Connections icon.
|
To specify parameters for an SNA Server that will be used for LU 6.2 (APPC), do the following:
To assign a local APPC LU to the Server, perform the following steps:
You can use an IBM-defined mode, or add a new mode that is appropriate for the application. Ensure that the values match between your client and server.
To configure a mode for the APPC LU, perform the following steps:
Based on whether the LU is local or remote, either the APPC LU Properties window or the New APPC LU Properties window opens.
![]() |
The rest of the values in our example are arbitrary. The values for items such as Parallel Session Limit and Minimum Contention Winner Limit are for tuning purposes. See the online help for SNA Server for guidance on setting these values.
|
To configure settings for a new connection, do the following:
The 802.2 Setup window opens.
To assign a remote APPC LU to a connection do the following:
To configure the properties for CPI-C, do the following:
![]() |
After you have finished updating your APPC client profile, go to "B. Catalog the APPC Node".
|
You must add an entry to the client's node directory to describe the remote node.
This entry specifies the chosen alias (node_name), Symbolic Destination Name (sym_dest_name), and the APPC security type (security_type) that the client will use for the APPC connection.
To catalog the APPC node, perform the following steps:
![]() |
If you have trouble logging on to the system, see Logging on to the System.
|
. INSTHOME/sqllib/db2profile (for Bourne or Korn shell) source INSTHOME/sqllib/db2cshrc (for C shell)
where INSTHOME is the home directory of the instance.
catalog appc node node_name remote sym_dest_name security security_type terminate
| Note: | The sym_dest_name parameter is case-sensitive and must exactly match the value used in A. Update the APPC Profiles. |
catalog appc node db2node remote NYSERVER security none terminate
![]() |
If you need to change values that were set with the catalog node command, first run the uncatalog node command in the command line processor as follows: uncatalog node node_name Recatalog the node with the value that you want to use.
|
Before a client application can access a remote database, the database must be cataloged on the server node and on any client nodes that will connect to it. When you create a database, it is automatically cataloged on the server with the database alias (database_alias) the same as the database name (database_name). The information in the database directory, along with the information in the node directory, is used on the client to establish a connection to the remote database.
To catalog a database on the client, perform the following steps.
![]() |
If you have trouble logging on to the system, see Logging on to the System.
|
Table 21. Worksheet: Parameter Values for Cataloging Databases
| Parameter | Description | Sample Value | Your Value |
|---|---|---|---|
| Database name (database_name) | The database alias (database_alias) of the remote database. When you create a database, it is automatically cataloged on the server with the database alias (database_alias) the same as the database name (database_name). | sample | |
| Database alias (database_alias) | An arbitrary local nickname for the remote database, on the client. If you do not provide one, the default is the same as the database name (database_name). This is the name that you use when connecting to a database from a client. | tor1 | |
| Node name (node_name) | The name of the node directory entry that describes where the database resides. Use the same value for node name (node_name) that you used to catalog the node in the previous step. | db2node |
![]() |
If you are configuring communications for a Windows 3.x client, you
can use the Client Setup tool to complete this task. Go to Using the Client Setup Tool to Configure a Windows 3.x Client to catalog a database using the Client Setup tool.
|
. INSTHOME/sqllib/db2profile (for Bourne or Korn shell) source INSTHOME/sqllib/db2cshrc (for C shell)where INSTHOME is the home directory of the instance.
catalog database database_name as database_alias at node node_name terminateFor example, to catalog a remote database called sample so that it has the alias tor1, on the node db2node, use:
catalog database sample as tor1 at node db2node terminate
![]() |
If you need to change values that were set with the catalog database command, first run the uncatalog database command in the command line processor as follows: uncatalog database database_alias Recatalog the database with the value that you want to use.
|
When the configuration of the client is complete, use the
following steps to verify that you can access data from a remote
database:
![]() |
You will need to connect to a remote database to test the
connection. If you do not have a database on the server, create the
sample database on the server to test the connection. Refer to the Quick Beginnings manual for more information.
|
connect to database_alias user userid using password
The values for userid and password must be valid for the system on which they are authenticated. By default, authentication takes place on the SERVER. If the database manager is configured for CLIENT authentication, the userid and password must be valid on the client.
If the connection is successful, you will get a message showing the name of the database to which you have connected. You are now able to retrieve data from that database. For example, to retrieve a list of all the table names listed in the system catalog table, enter the following SQL command in the Command Center or command line processor:
"select tabname from syscat.tables"
When you are finished using the database connection, enter the connect
reset command to end the database connection.
![]() |
You are ready to start using the DB2 server. See Chapter 11. Getting Started with DB2 Universal Database for details.
|
If the connection fails, check the following items:
At the server:
![]() |
Check the settings for the db2comm registry value by entering the
db2set DB2COMM command. For more information, see Chapter 15. Controlling Your DB2 Environment.
|
![]() |
If there are problems starting a protocol's connection managers, a warning message is displayed and the error messages are logged in the db2diag.log file. Refer to the Troubleshooting Guide for information on the db2diag.log file.
|
At the client:
After you verify these items, refer to the Troubleshooting Guide if the connection still fails.