To access a remote server through TCP/IP, you must first have installed and configured communication software for both the client and DB2 server workstations. See "Software Requirements" for the communication protocol requirements for your platform. See "Possible Client-to-DB2 Server Connectivity Scenarios" for the supported communication protocols for your particular client and server.
Before completing the steps in this section, be sure that you have
completed the instructions in "Setting the DB2COMM Registry Value".
| If you are setting up communications for the Administration Server, it was configured for TCP/IP (using the registered Port number 523) when it was created. There are no further steps required to enable the Administration Server to use TCP/IP. |
The following steps are required to set up TCP/IP 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 18. TCP/IP Values Required at the Server
Parameter | Explanation | Sample Value | Your Value |
---|---|---|---|
Connection Port
Interrupt Port
|
Values required in the services file. The Connection and Interrupt Service names are arbitrary, but each must be unique within the services file; ensure that this number does not conflict with the port numbers used by the Fast Communication Manager (FCM). The Connection and Interrupt Ports must be unique within the
services file, with the Interrupt Port number equal to the
Connection Service Port number plus one.
|
server1
3700/tcp
server1i
3701/tcp
| |
Service name (svcename)
|
The name used to update the Service name (svcename) parameter in
the database manager configuration file at the server. This value must
be the same as the Connection Service name specified in the
services file.
| server1 |
The following steps describe how to configure this protocol on the server. Replace the sample values with your values and record them on your worksheet.
The TCP/IP services file specifies ports that the DB2 server will listen on for client requests. The services file must contain two entries for each database manager instance.
You need to update the services file and specify the ports that you want the DB2 server to listen on for incoming client requests. The first entry describes the Connection Port, and the second entry describes the Interrupt Port.
The services file is located in the /etc
directory.
Using a local text editor, add the Interrupt Port and Connection Port entries to the services file for TCP/IP support. For example:
server1 3700/tcp # DB2 connection service port server1i 3701/tcp # DB2 interrupt connection service port
where:
You must update the database manager configuration file with the Service name (svcename) parameter.
To update the database manager configuration file, 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.
update database manager configuration using svcename svcename db2stop db2start
For example, if the Connection Service name in the services file was entered as server1, use:
update database manager configuration using svcename server1 db2stop db2start
|
The svcename used must match the Connection Service name specified
in the services file.
|
After the database manager is stopped and started again, view the database manager configuration file to ensure that these changes have taken effect. Enter the following command in the command line processor:
get database manager configuration
|
Now that you have configured the server, you are ready to install a DB2
client. Go to Chapter 8. "Installing DB2 Clients" for more information.
|