DB2 V7 Quick Beginning
DB2 V7 Quick Beginning
GC09-2964-01
® ®
IBM DB2 Universal Database
Enterprise - Extended Edition
for UNIX
®
Quick Beginnings
Version 7
GC09-2964-01
Before using this information and the product it supports, be sure to read the general information under
“Appendix G. Notices” on page 259.
This document contains proprietary information of IBM. It is provided under a license agreement and is protected by
copyright law. The information contained in this publication does not include any product warranties, and any
statements provided in this manual should not be interpreted as such.
Order publications through your IBM representative or the IBM branch office serving your locality or by calling
1-800-879-2755 in the United States or 1-800-IBM-4YOU in Canada.
When you send information to IBM, you grant IBM a nonexclusive right to use or distribute the information in any
way it believes appropriate without incurring any obligation to you.
© Copyright International Business Machines Corporation 1993, 2000. All rights reserved.
US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract
with IBM Corp.
Contents
Welcome to DB2 Universal Database! . . vii Step 2. Create the Administration Server 40
Conventions . . . . . . . . . . . . vii Step 3. Update the Node Configuration
File . . . . . . . . . . . . . . 40
Part 1. About DB2 Universal Step 4. Enable the Fast Communications
Manager . . . . . . . . . . . . 43
Database . . . . . . . . . . . . 1 Step 5. Modify the Environment to run
DB2 Enterprise - Extended Edition . . . 45
Chapter 1. Introduction to DB2 Enterprise - Step 6. Enable the Execution of Remote
Extended Edition . . . . . . . . . . 3 Commands . . . . . . . . . . . 47
Processing in a Partitioned Database Step 7. Create Links for DB2 Files
Environment . . . . . . . . . . . . 4 (Optional) . . . . . . . . . . . . 48
Cost-Based Query Optimization . . . . . . 4 Step 8. Start the Administration Server . . 48
Configuration . . . . . . . . . . . . 5 Step 9. Create the SAMPLE Database
Machines and Storage . . . . . . . . 7 (Optional) . . . . . . . . . . . . 50
Nodegroups and Data Partitioning . . . . 8 Step 10. Install the License Key . . . . 52
Multiple Logical Nodes . . . . . . . 10
Instances . . . . . . . . . . . . 11 Chapter 4. Installing and Configuring DB2
Fast Communications Manager . . . . 12 Universal Database on HP-UX . . . . . 53
High Availability . . . . . . . . . 13 Before You Begin . . . . . . . . . . 53
Performing the Installation . . . . . . . 57
Part 2. Installing DB2 Servers . . . 15 Post Installation Steps . . . . . . . . . 59
Step 1. Create a DB2 Instance . . . . . 59
Chapter 2. Planning for Installation . . . 17 Step 2. Create the Administration Server 60
Memory Requirements . . . . . . . . 17 Step 3. Update the Node Configuration
Disk Requirements . . . . . . . . . . 18 File . . . . . . . . . . . . . . 61
DB2 Servers . . . . . . . . . . . 18 Step 4. Enable the Fast Communications
DB2 Clients . . . . . . . . . . . 18 Manager . . . . . . . . . . . . 63
Software Requirements . . . . . . . . 19 Step 5. Enable the Execution of Remote
Server Product Requirements . . . . . 19 Commands . . . . . . . . . . . 65
Client Product Requirements . . . . . 21 Step 6. Create Links for DB2 Files
Possible Client-to-Server Connectivity (Optional) . . . . . . . . . . . . 65
Scenarios . . . . . . . . . . . . . 26 Step 7. Start the Administration Server . . 66
Migrating from Previous Versions of DB2 . . 27 Step 8. Create the SAMPLE Database
Preparing Databases and Instances for (Optional) . . . . . . . . . . . . 67
Migration . . . . . . . . . . . . 27 Step 9. Install the License Key . . . . . 68
NetQuestion Search System . . . . . . . 29
Your next step . . . . . . . . . . . 29 Chapter 5. Installing and Configuring DB2
Universal Database on Linux. . . . . . 71
Chapter 3. Installing and Configuring DB2 Before You Begin . . . . . . . . . . 71
Universal Database on AIX . . . . . . 31 Performing the Installation . . . . . . . 75
Before You Begin . . . . . . . . . . 31 Post Installation Steps . . . . . . . . . 76
Performing the Installation . . . . . . . 37 Step 1. Create a DB2 Instance . . . . . 77
Post Installation Steps . . . . . . . . . 38 Step 2. Create the Administration Server 78
Step 1. Create a DB2 Instance . . . . . 39 Step 3. Update the Node Configuration
File . . . . . . . . . . . . . . 79
Chapter 6. Installing and Configuring DB2 Chapter 9. Your Next Step . . . . . . 131
Universal Database for NUMA-Q . . . . 89 DB2 Universal Database Administration
Before You Begin . . . . . . . . . . 89 Guide . . . . . . . . . . . . . . 131
Performing the Installation . . . . . . . 92 DB2 Universal Database Administration
Post Installation Steps . . . . . . . . . 93 Guide: Planning . . . . . . . . . 131
Step 1. Create a DB2 Instance . . . . . 94 DB2 Universal Database Administration
Step 2. Create the Administration Server 95 Guide: Implementation . . . . . . . 132
Step 3. Update the Node Configuration DB2 Universal Database Administration
File . . . . . . . . . . . . . . 95 Guide: Performance . . . . . . . . 132
Step 4. Enable the Fast Communications Task Information in other DB2
Manager . . . . . . . . . . . . 99 Documentation . . . . . . . . . . 132
Step 5. Enable the Execution of Remote
Commands . . . . . . . . . . . 100
Part 3. Installing DB2 Clients . . 135
Step 6. Create Links for DB2 Files
(Optional) . . . . . . . . . . . 101
Step 7. Start the Administration Server 101 Chapter 10. Installing DB2 Clients . . . 137
Step 8. Create the SAMPLE Database DB2 Run-Time Client . . . . . . . . 137
(Optional) . . . . . . . . . . . 102 DB2 Administration Client . . . . . . . 138
Step 9. Install the License Key . . . . 103 DB2 Application Development Client . . . 138
Distributed Installation . . . . . . . . 138
DB2 Thin Client . . . . . . . . . . 139
Chapter 7. Installing and Configuring DB2
Universal Database on Solaris . . . . . 105
Before You Begin . . . . . . . . . . 105 Chapter 11. Installing DB2 Clients on
Performing the Installation . . . . . . . 111 Windows 32-Bit Operating Systems . . . 141
Post Installation Steps . . . . . . . . 112 Before You Begin Installing . . . . . . 141
Step 1. Create a DB2 Instance . . . . . 112 Installing Without Administrator
Step 2. Create the Administration Server 114 Authority . . . . . . . . . . . 141
Step 3. Update the Node Configuration Installation Steps . . . . . . . . . . 142
File . . . . . . . . . . . . . 114
Step 4. Enable the Fast Communications Chapter 12. Installing DB2 Clients on
Manager . . . . . . . . . . . . 117 OS/2 Operating Systems . . . . . . . 145
Step 5. Check Available Paging Space . . 118 Before You Begin Installing . . . . . . 145
Step 6. Enable the Execution of Remote Installation Steps . . . . . . . . . . 145
Commands . . . . . . . . . . . 119
Step 7. Create Links for DB2 Files Chapter 13. Installing DB2 Clients on
(Optional) . . . . . . . . . . . 119 UNIX Operating Systems. . . . . . . 149
Step 8. Start the Administration Server 120 Before You Begin . . . . . . . . . . 149
About the db2setup utility . . . . . . . 149
Contents v
Username, User ID, Group Name, and Monitoring Databases using DB2
Instance Name Rules. . . . . . . . . 209 Performance Monitor . . . . . . . 232
Workstation Name (nname) Rules . . . . 209 Viewing SQL Access Plans using Visual
DB2SYSTEM Naming Rules . . . . . . 211 Explain . . . . . . . . . . . . 232
Password Rules . . . . . . . . . . 211 Managing Connections to Databases using
the Client Configuration Assistant . . . . 233
Appendix D. About DB2 Universal Managing Warehouses using the Data
Database for UNIX, Windows, and OS/2 . 213 Warehouse Center . . . . . . . . . 234
DB2 Products . . . . . . . . . . . 213 Understanding the Administration Server 234
DB2 Everywhere . . . . . . . . . 213 Developing Applications using the DB2
DB2 Universal Database . . . . . . 214 Application Development Client . . . . . 235
Host Databases . . . . . . . . . 216 Running Your Own Applications. . . . . 236
DB2 Connect . . . . . . . . . . . 216
Related Products . . . . . . . . . . 217 Appendix E. Using the DB2 Library . . . 237
DB2 Relational Connect . . . . . . . 217 DB2 PDF Files and Printed Books . . . . 237
DB2 Warehouse Manager . . . . . . 217 DB2 Information . . . . . . . . . 237
DB2 OLAP Server. . . . . . . . . 218 Printing the PDF Books . . . . . . . 246
Intelligent Miner . . . . . . . . . 218 Ordering the Printed Books . . . . . 247
DB2 Spatial Extender . . . . . . . 218 DB2 Online Documentation . . . . . . 248
DB2 Net Search Extender . . . . . . 218 Accessing Online Help . . . . . . . 248
DB2 Data Links Manager . . . . . . 219 Viewing Information Online . . . . . 250
Tivoli Enterprise . . . . . . . . . 219 Using DB2 Wizards . . . . . . . . 252
Working with DB2 Data. . . . . . . . 219 Setting Up a Document Server . . . . 253
Accessing DB2 Data from Remote Clients 219 Searching Information Online . . . . . 254
Accessing Multiple DB2 Servers . . . . 220
Accessing Host or AS/400 DB2 Data from Appendix F. Removing DB2 Products . . 255
the Desktop using DB2 Connect Stop the Administration Server . . . . . 255
Enterprise Edition. . . . . . . . . 221 Stop all DB2 instances . . . . . . . . 255
Accessing DB2 Data from the Web using Remove the Administration Server . . . . 256
Java . . . . . . . . . . . . . 225 Remove DB2 instances (Optional) . . . . 257
Accessing DB2 Data from the Web using Remove DB2 Products . . . . . . . . 257
Net.Data . . . . . . . . . . . . 226
Accessing DB2 Data from Host and Appendix G. Notices . . . . . . . . 259
AS/400 Client Machines . . . . . . 228 Trademarks . . . . . . . . . . . . 262
Administering Instances and Databases with
the DB2 Administration Tools . . . . . . 228 Index . . . . . . . . . . . . . 265
Managing Instances and Database Objects
using the Control Center . . . . . . 228 Contacting IBM . . . . . . . . . . 269
Managing Communications on the Server 232 Product Information . . . . . . . . . 269
DB2
The DB2 Universal Database Quick
Beginnings books provide a focused
introduction to the installation and
configuration of DB2 products. Universal
This Quick Beginnings book will guide Database
you through the planning,
installation, migration (if necessary),
and setup of a partitioned database
system. After you have set up and
configured your partitioned database
system, you will create the SAMPLE
database. Finally, once the DB2 server
has been installed and the SAMPLE
database has been created, you will
install a DB2 client and configure a
connection between the client and
server using the DB2 GUI tools or
the Command Line Processor.
Conventions
This book uses the following highlighting conventions:
v Boldface indicates commands or graphical user interface (GUI) controls
such as names of fields, folders, icons, or menu choices.
v Italics indicates variables that you should replace with your own value. It is
also used to indicate book titles and to emphasize words.
v Monospace indicates file names, directory paths, and examples of text you
enter exactly as shown.
This icon marks a fast path. A fast path guides you to information
specific to your configuration where multiple options are available.
This icon marks a tip. It provides additional information that can help
you complete a task.
For a complete description of the DB2 library, see “Appendix E. Using the
DB2 Library” on page 237.
A partitioned database system can maintain very large databases and open
opportunities for new applications. DB2 EEE provides fast response time for
both decision-support (DSS) and online transaction processing (OLTP)
applications.
User interaction with DB2 EEE is handled through one of the database
partition servers (node). This database partition server is known as the
coordinator node for the partitioned database system. By default, every
database partition server in your partitioned database system can act as a
coordinator node. The database partition server that a client or application
connects to becomes the coordinator node. You should consider spreading out
users across database partitions servers to distribute the coordinator function.
For more information, refer to the Administration Guide.
Configuration
Figure 1 on page 6 shows an example of a DB2 Enterprise - Extended Edition
(DB2 EEE) hardware configuration.
. . . . . .
LAN LAN
Database Partition
Server
The following sections provide information that you should be familiar with
before you configure your partitioned database system. Specifically, they
describe:
v Machines and Storage
v Nodegroups and Data Partitioning
v Multiple Logical Nodes
v Instances
v Fast Communication Manager (FCM)
v High Availability
Machines and Storage
DB2 Enterprise - Extended Edition implements a shared-nothing architecture,
therefore each database partition server is the equivalent of a single-partition
database system. Thus, the database storage capacity for the partitioned
database system is equal to that provided by a single-partition database
system multiplied by the number of database partition servers. You can store
tables of up to 512 GB (gigabytes) per database partition. For example, in a
database that has 128 partitions, the maximum size of one table is
approximately 64 TB (terabytes).
If you want, you can create table spaces in the default nodegroups
IBMDEFAULTGROUP and IBMCATGROUP, and then create tables within
those table spaces.
Database
Nodegroup 2 Partition
Nodegroup 1
Database
Partition
Database
Partition
Database
Partition
Database
Nodegroup 3 Partition
When you want to create table spaces for a database, you first create the
nodegroup where the table spaces will be stored, then create a table space in
the nodegroup. After this, you create the tables in the table space.
You can drop database partitions from a nodegroup, or if new nodes have
been defined in the db2nodes.cfg file, you can add them to a nodegroup in a
database. For information about adding and dropping nodes in nodegroups,
refer to the Administration Guide.
As your database increases in size, you can add database partition servers to
the database system for improved performance. This is known as scaling the
database system. When you add a database partition server, a database
partition is created for each database that already exists in the database
system. You then add the new database partition to an existing nodegroup
For more information about creating nodegroups, refer to the SQL Reference.
For more information about using nodegroups, refer to the Administration
Guide.
Multiple Logical Nodes
Typically, you configure DB2 Enterprise - Extended Edition to have one
database partition server assigned to each machine. There are situations,
however, in which it would be advantageous to have more than one database
partition server assigned to each machine. If these database partition servers
(nodes) participate in the same instance, this is referred to as a Multiple
Logical Node (MLN) configuration.
A Multiple Logical Node (MLN) configuration is useful when the system runs
queries on a machine that has symmetric multiprocessor (SMP) architecture.
Another benefit is that multiple logical nodes can exploit SMP hardware
configurations. In addition, because database partitions are smaller, you can
obtain better performance when performing such tasks as backing up and
restoring database partitions and table spaces, and creating indexes. As a
general rule, we recommend that you run one MLN per 4 processors.
Depending on the operating system where you are running DB2 EEE, this
may vary for performance reasons.
Each instance has different security from other instances on the same machine.
This is shown in Figure 3, which shows two separate instances. Instance 1
contains six database partition servers and Instance 2 contains eight database
partition servers. (Multiple database partition servers are indicated when more
than one line is shown between a database partition server and the instance
directory.) The two instances overlap, but this is due to the assignment of two
database partition servers to each of the three machines in the middle of the
figure.
The db2nodes.cfg file for Instance 1 will not list the database partition servers
that belong to Instance 2, and the converse.
Database
Database Partition Database
Partition Server Partition
Database
Server Server
Partition
Servers
Database Database
Partition Partition
Server Servers
Database Database
Partition Partition
Servers INSTHOME 1 INSTHOME 2 Server
Instance 1 Instance 2
Figure 3. Two Instances
The instance owner has System Administrative (SYSADM) authority for all
databases that belong to the instance. Because the instance owner has almost
complete control over the instance, this user ID can:
v Issue the db2start and db2stop commands on the instance
v Modify database configuration parameters
v Modify database manager configuration parameters
v Grant privileges to and revoke them from other users
The instance owner cannot remove an instance. This requires root authority.
The FCM daemon is started when you start the instance. When the daemon
starts, it reads the node configuration file (INSTHOME/sqllib/db2nodes.cfg,
where INSTHOME is the home directory of the instance owner) and defines a
well-known address to use for communications.
You can specify the number of FCM message buffers with the
fcm_num_buffers database manager configuration parameter. For a
description of this and other FCM parameters, refer to the
Administration Guide.
High Availability
You can set up your partitioned database system so that if a machine fails, the
database server on the failed machine can run on another machine.
On Solaris systems, you implement failover support using Sun Cluster 2.2.
Sun Cluster 2.2 performs both failure detection and the restarting of resources
in a clustered environment, as well as failover support for physical disks and
IP addresses.
At this time, DB2 failover support for HP-UX, Linux and the PTX operating
system is a manual process requiring you to restart the failing node manually
on another node that has access to the failing node’s disk.
This chapter describes the following requirements you should take into
consideration before installing DB2:
v “Memory Requirements”.
v “Disk Requirements” on page 18.
v “Software Requirements” on page 19.
v “Possible Client-to-Server Connectivity Scenarios” on page 26.
v “Migrating from Previous Versions of DB2” on page 27.
If you know that your system meets all the hardware and software
requirements, and you want to begin installing your DB2 product right
away, go to:
v “Chapter 3. Installing and Configuring DB2 Universal Database on
AIX” on page 31
v “Chapter 4. Installing and Configuring DB2 Universal Database on
HP-UX” on page 53
v “Chapter 5. Installing and Configuring DB2 Universal Database on
Linux” on page 71
v “Chapter 6. Installing and Configuring DB2 Universal Database for
NUMA-Q” on page 89
v “Chapter 7. Installing and Configuring DB2 Universal Database on
Solaris” on page 105
Memory Requirements
The amount of random-access memory (RAM) that you require to run your
DB2 server depends on the size of your databases and on the administration
tools you will use. For example, if you plan to use the DB2 GUI tools to
administer and configure your DB2 databases, the minimum amount of RAM
we recommend is 128 MB.
Disk Requirements
The actual fixed disk requirements of your installation may vary depending
on your file system and the components you install. Ensure that you have
included a disk space allowance for your operating system, application
development tools, application data, and communications products. For more
information about space requirements for data, refer to the Administration
Guide.
DB2 Servers
A default installation of DB2 requires a minimum of 250 to 300 MB of disk
space. This amount includes the online production documentation and tools.
On NUMA-Q systems, a default installation requires a minimum of 80 MB.
DB2 Clients
Use Table 1 to estimate the amount of disk space you need on each of your
client workstations. You may require additional amounts of disk space
depending on your file system.
Table 1. Disk Requirements for Client Components
Client Components Recommended Minimum Disk (MB)
OS/2
DB2 Run-Time Client 30 MB
DB2 Application Development Client 125 MB, not including the Java
Development Kit (JDK)
DB2 Administration Client 95 MB
UNIX platforms
DB2 Run-Time Client 30 to 40 MB (70 MB for Silicon Graphics
IRIX)
DB2 Application Development Client 90 to 120 MB, not including the JDK (40
MB for NUMA-Q)
DB2 Administration Client 80 to 110 MB
Software Requirements
This section outlines the software required to run DB2 products.
Server Product Requirements
Table 2 lists the operating system and communications software required for
DB2 Universal Database.
On all platforms you will need a Java Runtime Environment (JRE) Version
1.1.8 to run DB2’s Java-based tools, such as the Control Center. If you intend
to run the Control Center as an applet, you will need a Java-enabled browser.
See “Chapter 14. Control Center Installation and Configuration” on page 155
for more information.
Table 2. Software Requirements
Hardware/Software Requirements Communications
DB2 Universal Database for AIX
Notes:
1. If you plan to use the DB2 OLAP Starter Kit, you require AIX Version 4.3 or later.
2. For LDAP (Lightweight Directory Access Protocol) support, you require an IBM
SecureWay Directory Client V3.1.1 running on AIX V4.3.1 or higher.
3. For Data Links Manager in DCE-DFS environments, you require DCE Version 3.1.
4. If you plan to use DCE (Distributed Computing Environment) and you are not using
DB2 Data Links Manager, you require a DCE product that is provided with your AIX
operating system. For DB2 Connect support, you require DB2/MVS Version 5.1 plus
its prerequisite, OS/390 DCE Base Services Version 3 for DCE support.
With DB2 Connect, you must install DCE Directory Services on the client and the
DRDA server. You do not need DCE installed on a DB2 Connect Enterprise Edition
server.
5. If you plan to use the Tivoli Storage Manager facilities back up and restore to your
databases, you require the Tivoli Storage Manager Client Version 3 or later.
6. If you plan to use the Simple Network Management Protocol (SNMP) subagent, you
require DPI 2.0 provided by IBM SystemView Agent.
DB2 Universal Database for HP-UX
HP 9000 series 700 or 800 system and the APPC or TCP/IP
following: v TCP/IP is provided with the HP-UX base operating system.
v HP-UX Version 11.00 or later v For APPC connectivity, HP-UX Version 11.00 requires the following:
– SNAplus2 Link R6.11.00.00
– SNAplus2 API R.6.11.00.00
Notes:
1. HP-UX only supports outbound client APPC requests. It does not provide support for
inbound client APPC requests.
2. If you plan to use DCE (Distributed Computing Environment), you require a DCE
product that is provided by the HP-UX Version 11 operating system.
With DB2 Connect, you must install DCE Directory Services on the client and the host
server. You do not need DCE installed on a DB2 Connect Enterprise Edition server.
3. If you plan to use the Tivoli Storage Manager facilities to back up and restore your
databases, you require the Tivoli Storage Manager Client Version 3 or later.
v glibc Version 2.1.2 or higher; v For TCP/IP connectivity, no additional software is required.
v pdksh package 5.2 or greater (required v APPC connectivity is not supported in this version of DB2 UDB for Linux.
to run the DB2 command line v To run the Control Center, or any DB2 Java utility you must install the IBM Developer
processor); and Kit for Java March 22, 2000 release or later.
v libstdc++ Version 2.9.0.
Notes:
1. If you plan to use DCE (Distributed Computing Environment), you require Transarc
DCE Version 2.0 or later.
With DB2 Connect, you must install DCE Directory Services on the client and the
DRDA server. You do not need DCE installed on a DB2 Connect Enterprise Edition
server.
2. If you plan to use the Tivoli Storage Manager facilities for backup and restore of your
databases, you require the Tivoli Storage Manager Client Version 3 or later.
On all platforms you will need a Java Runtime Environment (JRE) Version
1.1.8 to run the DB2 tools, such as the Control Center. If you intend to run the
Control Center as an applet on Windows 32-bit or OS/2 systems, you will
need a Java-enabled browser. See “Chapter 14. Control Center Installation and
Configuration” on page 155 for more information.
v DB2 Run-Time Client v OS/2 Warp Version 4 APPC, IPX/SPX, NetBIOS, or TCP/IP
for OS/2 v OS/2 Warp Server Version v For APPC connectivity, you require IBM eNetwork
v DB2 Administration 4 Communications Server for OS/2 Warp Version 5 or IBM
Client for OS/2 eNetwork Personal Communications for OS/2 Warp
v OS/2 Warp Server Version 4.2.
v DB2 Application Advanced V4
Development Client v For IPX/SPX connectivity, you require the Novell NetWare
v OS/2 Warp Server client for OS/2 Version 2.10 or later. IPX/SPX can only be
for OS/2 Advanced V4 with SMP used to connect to databases. It cannot be used to connect
Feature to host or AS/400 databases.
v OS/2 Warp Server for v The OS/2 base operating system provides NetBIOS and
e-business TCP/IP connectivity, if selected during installation.
Note: When the DB2 v The OS/2 base operating system provides Named Pipes
Application Development (Local) connectivity. Named Pipes is supported in DOS
Client is installed, the JDK is and WIN-OS/2 sessions.
not installed. You can install
the latest version of the JDK Notes:
from your product 1. Net.Data requires a Web server such as WebSphere.
CD-ROM. 2. For DCE Cell Directory Services Support (CDS) for DB2
Clients for OS/2, you must install an IBM Distributed
Computing Environment Cell Directory Service client on
each client workstation.
3. If you are planning to use Tivoli Storage Manager, PTF 3
for Tivoli Storage Manager Version 3 is required for an
OS/2 client.
v DB2 Run-Time Client v Windows 95 4.00.950 or IPX/SPX, Named Pipes, NetBIOS, or TCP/IP
for Windows 9x later v The Windows 9x base operating system provides NetBIOS,
v DB2 Administration v Windows 98 IPX/SPX, TCP/IP, and Named Pipes connectivity.
Client for Windows Note: IPX/SPX connectivity is only supported to
9x Note: When the DB2 Windows NT and Windows 2000 servers.
Application Development v If you plan to use LDAP (Lightweight Directory Access
v DB2 Application Client is installed, the JDK
Development Client Protocol), you require either a Microsoft LDAP client or an
1.1.8 is installed. IBM SecureWay LDAP client V3.1.1. For more information,
for Windows 9x
refer to the Administration Guide.
v If you plan to use the Tivoli Storage Manager facilities for
backup and restore of your databases, you require the
Tivoli Storage Manager Client Version 3 or later.
v If you have the IBM Antivirus program installed on your
operating system, it must be disabled or uninstalled to
complete a DB2 installation.
v DB2 Run-Time Client v Windows NT Version 4.0 APPC, IPX/SPX, Named Pipes, NetBIOS, or TCP/IP
for Windows with Service Pack 3 or v The Windows NT and Windows 2000 base operating
v DB2 Administration later systems provide NetBIOS, IPX/SPX, TCP/IP, and Named
Client for Windows v Windows Terminal Server Pipes connectivity.
v DB2 Application (can only run the DB2 v For APPC connectivity, you require one of the following
Development Client Run-Time Client) products:
for Windows v Windows 2000 – IBM eNetwork Communications Server for Windows
V5.01 or later.
Note: When the DB2
Application Development – Windows 2000: IBM eNetwork Personal
Client is installed, the JDK Communications for Windows Version 4.3 CSD2 or later
1.1.8 is installed. – Windows NT: IBM eNetwork Personal Communications
for Windows Version 4.2 or later
– Microsoft SNA Server Version 3 Service Pack 3 or later
– Wall Data Rumba
v If you plan to use DCE (Distributed Computing
Environment) and connect to a DB2 for OS/390 V5.1
database, that database must be enabled for DCE support
using OS/390 DCE Base Services Version 3.
v If you plan to use LDAP (Lightweight Directory Access
Protocol), you require either a Microsoft LDAP client or an
IBM SecureWay LDAP client V3.1.1. For more information,
refer to the Administration Guide.
v If you plan to use the Tivoli Storage Manager facilities for
backup and restore of your databases, you require the
Tivoli Storage Manager Client Version 3 or later.
v If you have the IBM Antivirus program installed on your
operating system, it must disabled or uninstalled to
complete a DB2 installation.
1. Direct Addressing
2. File Server Addressing
When you migrate from a Version 5.x or Version 6 database system to a DB2
Enterprise - Extended Edition Version 7 database system, depending on the
installation option you choose, the installation program will migrate all
instances to the Version 7 multipartition or single-partition format. If you are
migrating a database with populated tables, refer to the Administration Guide
for descriptions of how to add database partition servers to a system and
redistribute data across database partitions.
After you install DB2 Enterprise - Extended Edition, any databases that you
created with earlier versions of DB2 will not automatically work with the new
version of DB2. You must follow the steps in this section to migrate your
instances and then to move data from the previous database system to the
new one. Although your data is not changed during the process, the database
is different from the original one. The differences depend on the type of
database system from which you are migrating.
Preparing Databases and Instances for Migration
This section describes how to prepare existing DB2 Version 5.x databases and
instances for migration to a format usable by DB2 Version 7. If you want to
migrate more than one instance, you must repeat these steps for each instance.
If the version of NetQuestion that comes with DB2 Version 7 is later than the
version of NetQuestion currently present on your system, the current version
will be upgraded and any existing document indices will be re-registered with
NetQuestion. This will be done automatically for you during DB2 installation.
The instructions in this section assume that you are installing DB2
Enterprise - Extended Edition (DB2 EEE) for AIX in an RS/6000 SP
environment.
Before you begin the installation, be sure that you have the following items
and information:
1. Ensure that your system meets all of the memory, hardware, and
software requirements to install your DB2 product. For more information,
see “Chapter 2. Planning for Installation” on page 17.
2. The hostname of the Control workstation and all the workstations that
will participate in your partitioned database system. To resolve a
workstation’s hostname, log on to the workstation and enter the
following command:
hostname
3. Have a file that lists the hostnames for all of the RS/6000 SP
workstations that will participate in your partitioned database system. Set
You should not mount this file system using the AMD or
automounter utilities. These utilities can cause NFS mounting or
locking problems in a partitioned database system.
Step d. NFS export the /home2 file system so that it is available to all of
the RS/6000 SP workstations that will participate in your
partitioned database system by performing the following steps:
1) Enter the smit nfs command.
2) Click on the Network File System (NFS) icon.
3) Click on the Add a Directory to Exports List icon.
If you are using NIS or NIS+, groups and users must be created on
the NIS server before running db2setup.
Step b. Create a group for the instance owner (for example, db2iadm1), the
user that will execute UDFs or stored procedures (for example,
db2fadm1), and the Administration Server (for example, db2asgrp)
by entering the following commands:
mkgroup id=999 db2iadm1
mkgroup id=998 db2fadm1
mkgroup id=997 db2asgrp
If you are using NIS or NIS+, secondary groups must be created for
the DB2 instance owner and the Administration Server on the NIS
server. You must then add the primary group of the instance owner
to the secondary Administration Server group. Likewise, you must
add the primary Administration Server group to the secondary
group for the instance owner.
Step c. Create a user that belongs to each group that you created in the
previous step by entering the following commands:
mkuser id=1004 pgrp=db2iadm1 groups=db2iadm1 home=/home2/db2inst1
core=-1 data=491519 stack=32767 rss=-1 fsize=-1 db2inst1
mkuser id=1003 pgrp=db2fadm1 groups=db2fadm1 home=/home2/db2fenc1
db2fenc1
mkuser id=1002 pgrp=db2asgrp groups=db2asgrp home=/home2/db2as
db2as
Step d. Set an initial password for each user that you created by entering
the following commands:
passwd db2inst1
passwd db2fenc1
passwd db2as
Step e. Log out.
Step f. Log on to the Control workstation as each user that you created
(db2inst1, db2fenc1, and db2as). You will be prompted to change
each user’s password since this is the first time that these users
have logged onto the system.
Step g. Log out.
Step h. Log on to the Control Workstation as a user with root authority.
Step i. Distribute each group and user account that you created to the
other SP workstations that will participate in your partitioned
database system by entering the following command:
dsh /var/sysman/supper update user.admin
If you do not issue the dsh command, the cron job will automatically
create these groups and user accounts when it is automatically run.
The default setting is 10 minutes past the hour.
Step 7. The db2_07_01.xlic fileset will only install those components that are
required to run DB2 EEE. This fileset will not install the Control
Center and only install the English version of the DB2 messages. To
install any non-English DB2 messages, or the Control Center, perform
the following steps:
Step a. Enter the smit install command.
Step b. Click on the Install and Update Software icon.
You can use to this method to install any other DB2 components that
were not installed by default.
This section describes how to create an instance using the DB2 Installer
program. We recommend that you use DB2 Installer program to create an
instance because it will configure the instance automatically for
communications.
For information on how to create an instance using the db2icrt command, and
configure it for communications, refer to the Administration Guide and the
Installation and Configuration Supplement online document.
To create an instance using the DB2 Installer program, perform the following
steps:
Step 1. Log on as a user with root authority to the RS/6000 SP workstation
where you installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /usr/lpp/db2_07_01/install/db2setup command to start the
DB2 Installer program. The DB2 Installer window opens.
Step 3. Select the Create option and press the Enter key.
Press the Tab key to change a highlighted option and the Enter key
to select or deselect the option you want. For more information on
using the DB2 Installer program, or for help with any task you are
performing with the DB2 Installer, select the Help option and press
the Enter key.
Step 4. Select the Create a DB2 Instance option and press the Enter key.
Step 5. Fill in all of the fields for the username that you created for the
instance owner in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key.
Step 7. Fill in all of the fields for the username that you created to execute
fenced UDFs and stored procedures in “Before You Begin” on
page 31.
Step 8. Select the OK option and press the Enter key. You are returned to
the Create DB2 Services window.
Step 9. Select the OK option and press the Enter key. You will receive a
warning message that you have not yet created the Administration
Server. You can ignore this message. The Summary Report window
opens.
We recommend that you use the DB2 Installer program to create the
Administration Server because it will configure the Administration Server
automatically for communications. For information on how to create an
instance using the dasicrt command, and configure it for communications,
refer to the Administration Guide and the Installation and Configuration
Supplement online document.
To create the Administration Server using the DB2 Installer program, perform
the following steps:
Step 1. Log on as a user with root authority to the RS/6000 SP workstation
where you installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /usr/lpp/db2_07_01/install/db2setup command to start the
DB2 Installer program. The DB2 Installer window opens.
Step 3. Select the Create option and press the Enter key.
Step 4. Select the Create the Administration Server option and press the
Enter key.
Step 5. Fill in the fields for the username that you created for the
Administration Server in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key. You are returned to the
Create DB2 Services window.
Step 7. Select the OK option and press the Enter key. The Summary Report
window opens.
Step 8. Select the Continue option and press the Enter key. The DB2 Installer
program will prompt you to complete this task. When you have
completed this task, you are returned to the DB2 Installer window.
Step 9. Select the Close option and press the Enter key.
Step 3. Update the Node Configuration File
The node configuration file (db2nodes.cfg), located in the INSTHOME/sqllib/
directory (where INSTHOME is the home directory of the instance owner)
contains configuration information for all the database partition servers that
are participating in the instance. There is a db2nodes.cfg file for every
For example, when you created the DB2 instance db2inst1, on the workstation
called workstation1, the db2nodes.cfg file was updated as follows:
0 workstation1 0
If you are not using a clustered environment and want to have four database
partition servers on one physical workstation called workstation1, update the
db2nodes.cfg file as follows:
0 workstation1 0
1 workstation1 1
2 workstation1 2
3 workstation1 3
The db2nodes.cfg file is locked when the instance is running and can
only be edited when the instance is stopped.
3. Edit the db2nodes.cfg file and add an entry for each database partition
server that will participate in your partitioned database system.
4. Enter the INSTHOME/sqllib/adm/db2start command, where INSTHOME is
the home directory of the instance owner.
5. Log out.
For more information on the db2nodes.cfg file, see the Administration Guide.
Step 4. Enable the Fast Communications Manager
If you are using Network Information Services (NIS), NIS+, or any
other tools to manage system configuration files, you must perform
this step on the master server. After you have completed this step,
you should ensure that the changes have taken effect on all the
RS/6000 SP workstations in your partitioned database system.
When you created a DB2 instance using the db2setup utility, an entry similar
to the following was placed in the /etc/services file:
DB2_instance_name 60000/tcp
where:
v instance_name is the name of the multipartition instance.
The port 60000 is the default FCM port used for any instance that
was created using the db2setup utility.
For example, if you created an instance called db2inst1, the entry placed in
the /etc/services file is:
DB2_db2inst1 60000/tcp
If you are planning to run multiple logical nodes (MLNs), you must reserve a
range of consecutive ports (one for each logical node). The consecutive port
range that you reserve must be equal to the number of MLNs on the database
partition server that is running the most MLNs in your partitioned database
system. To reserve a port range for FCM to use, you need to add another
entry to the /etc/services file that specifies the end of the port range. This
entry must be of the format:
DB2_instance_name_END port_number
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number of the last port in the port range that you
reserved for database partition server communications.
For example, if you have a database partition server that is running four
database partitions, you will need to specify four consecutive ports as your
port range. In our example, the entry in the /etc/services file is:
DB2_db2inst1 60000/tcp
DB2_db2inst1_END 60003/tcp
You can add a comment that describes these entries using the #
comment identifier. For example:
DB2_db2inst1 60000/tcp # This is an EEE instance
DB2_db2inst1_END 60003/tcp # that is running 4 MLNs.
where:
The above values are the minimum values for these parameters. If
you are already setting any of these network-related parameters to a
higher value, do not set the parameter to the lower listed value.
For a list of all the network parameters that are set on a workstation,
enter the no -a command.
To list the current settings of these parameters, enter the dsh -a lsattr
-l css0 -E command.
If you decide to create an /etc/hosts.equiv file, you have to create this file
on every workstation that participates in your partitioned database system.
You may want to create these links if you are developing or running
applications and want to avoid having to specify the full path to the product
libraries and include files.
To create links for the DB2 files, perform the following steps:
Step 1. Log on to the Control workstation as a user with root authority.
Step 2. Enter the following command to create the links for the DB2 files:
dsh /usr/lpp/db2_07_01/cfg/db2ln
If there are existing links to the /usr/lib and /usr/include directories from
previous versions of DB2 EEE, they will automatically be removed by
executing the db2ln command to create links for this version of DB2 EEE.
Step 8. Start the Administration Server
Before you can use the Client Configuration Assistant (CCA) or the Control
Center to administer your partitioned database system, you must ensure the
Administration Server is started and the db2cclst daemon is running on
every system in your partitioned database system.
If the /etc/services file is part of file collections, you must add this
entry to the /etc/services file on the Control workstation and
update each workstation using the following command:
dsh -a /var/sysman/supper update user.admin
where:
v INSTHOME is the home directory of the instance owner.
v DASINSTHOME is the home directory of the Administration
Server.
Step 11. Ensure that the db2cclst daemon is running by entering the
following command:
ps -ef | grep db2cclst
For more information on how to create a file system, see your Linux
documentation.
To verify that you have installed and configured DB2 EEE, perform the
following steps:
1. Log on to the system as a user with system administrative (SYSADM)
authority (by default, the username that you created for the instance
owner). For more information, see “Working with the System
Administrative Group” on page 199.
2. Enter the following command to create the SAMPLE database:
INSTHOME/sqllib/bin/db2sampl path
where:
v INSTHOME is the home directory of the instance owner.
v path is a local file system that exists on every workstation that
participates in your partitioned database system.
For example, to create the SAMPLE database on the /database file system,
enter the following command:
INSTHOME/sqllib/bin/db2sampl /database
After you have verified the installation, you can remove the SAMPLE
database to free up disk space. Enter the db2 drop database sample
command to drop the SAMPLE database.
where license_filename is the full pathname and filename for the license
file that corresponds to the product you have purchased.
For example, if the CD-ROM is mounted in the /cdrom directory and the
name of the license file is db2udbeee.lic, you would enter the following
command:
/usr/lpp/db2_07_01/cfg/db2licm /cdrom/db2/license/db2udbeee.lic
You can also use the Control Center to manage and monitor your
DB2 licensing agreement and to monitor database usage. To manage
licensing using the Control Center, perform the following steps:
Step 1. Start the Control Center. For more information, see “Starting
the DB2 Control Center” on page 195.
Step 2. Click on the License Center icon from the Control Center
toolbar. The License Center opens.
Step 3. Complete the steps to upgrade your DB2 license. For more
information, refer to the License Center’s online help by
pressing the F1 key.
We assume in these instructions that you install and configure DB2 Enterprise
- Extended Edition (DB2 EEE) using the DB2 install program. We also assume
that you select to install the Control Center, create an instance, and create the
Administration Server using the DB2 Installer program.
If you want to install your DB2 product using your UNIX operating system’s
native installation tools, refer to the Installation and Configuration Supplement.
The instructions in this section assume that you are installing DB2
Enterprise - Extended Edition (DB2 EEE) for HP-UX on one system
and running Multiple Logical Nodes (MLNs) to create your
partitioned database system. If you are installing DB2 EEE on a
cluster, you will have to run the DB2 Installer program on each
physical machine that you want to participate in your partitioned
database system.
Before you begin the installation, be sure that you have the following items
and information:
1. Ensure that your system meets all of the memory, hardware, and software
requirements to install your DB2 product. For more information, see
“Chapter 2. Planning for Installation” on page 17.
2. Have a file system that is available to all of the systems that will
participate in your partitioned database system. This file system will be
If you are using NIS or NIS+, groups and users must be created on
the NIS server before running db2setup.
The usernames you create must conform to both your operating system’s
naming rules, and those of DB2. You can have the DB2 Installer create
these usernames, or you can create them manually. For more information
on naming rules, see “Appendix C. Naming Rules” on page 207.
If you are using NIS or NIS+, secondary groups must be created for
the DB2 instance owner and the Administration Server on the NIS
server. You must then add the primary group of the instance owner
to the secondary Administration Server group. Likewise, you must
add the primary Administration Server group, to the secondary
group for the instance owner.
Notes:
1) The msgseg parameter must be set no higher than 32767.
2) The msgmnb and msgmax parameters must be set to at least
65 535.
3) The shmmax parameter should be set to 134 217 728 or 90% of
the physical memory (in bytes), whichever is higher. For
example, if you have 196 MB of physical memory in your
system, set shmmax to 184968806 (196*1024*1024*0.9).
4) To maintain the interdependency among kernel parameters,
change parameters in the same sequence in which they appear
in the preceding table.
When you use the DB2 Installer program, you should be aware of
the following:
v The DB2 Installer’s db2setup command only works with bash,
Bourne, and Korn shells. Other shells are not supported.
v You can generate a trace log, db2setup.trc, to record errors
experienced during the installation. Run the db2setup command
as follows:
db2setup -d
Step 7. When you have finished selecting the DB2 product and its
components, select OK to continue with the installation.
For more information or assistance during the installation of any DB2
product or component, select the Help option.
Step 8. Log out.
This section describes how to create an instance using the DB2 Installer
program. We recommend that you use DB2 Installer program to create an
instance because it will configure the instance automatically for
communications.
For information on how to create an instance using the db2icrt command, and
configure it for communications, refer to the Administration Guide and the
Installation and Configuration Supplement online document.
To create an instance using the DB2 Installer program, perform the following
steps:
Step 1. Log on as a user with root authority on a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Press the Tab key to change a highlighted option and the Enter key
to select or deselect the option you want. For more information on
using the DB2 Installer program, or for help with any task you are
performing with the DB2 Installer, select the Help option and press
the Enter key.
We recommend that you use the DB2 Installer program to create the
Administration Server because it will configure the Administration Server
automatically for communications. For information on how to create an
instance using the dasicrt command, and configure it for communications,
refer to the Administration Guide and the Installation and Configuration
Supplement online document.
To create the Administration Server using the DB2 Installer program, perform
the following steps:
Step 1. Log on as a user with root authority to a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Step 4. Select the Create the Administration Server option and press the
Enter key.
Step 5. Fill in the fields for the username that you created for the
Administration Server in “Before You Begin” on page 31.
For example, when you created the DB2 instance db2inst1, on the workstation
called workstation1, the db2nodes.cfg file was updated as follows:
0 workstation1 0
If you are not using a clustered environment and want to have four database
partition servers on one physical workstation called workstation1, update the
db2nodes.cfg file as follows:
0 workstation1 0
1 workstation1 1
2 workstation1 2
3 workstation1 3
The db2nodes.cfg file is locked when the instance is running and can
only be edited when the instance is stopped.
3. Edit the db2nodes.cfg file and add an entry for each database partition
server that will participate in your partitioned database system.
4. Enter the INSTHOME/sqllib/adm/db2start command, where INSTHOME is
the home directory of the instance owner.
5. Log out.
For more information on the db2nodes.cfg file, see the Administration Guide.
Step 4. Enable the Fast Communications Manager
This section describes how to enable communication between the database
partition servers that participate in your partitioned database system.
Communication between database partition servers is handled by the Fast
Communications Manager (FCM). To enable FCM, you must ensure that the
port or port range that you reserve in the /etc/services file is available on
every workstation in your partitioned database system.
When you created a DB2 instance using the db2setup utility, an entry similar
to the following was placed in the /etc/services file:
DB2_instance_name 60000/tcp
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number that you reserve for database partition
server communications.
The port 60000 is the default FCM port used for any instance that
was created using the db2setup utility.
For example, if you created an instance called db2inst1, the entry placed in
the /etc/services file is:
DB2_db2inst1 60000/tcp
If you are planning to run multiple logical nodes (MLNs), you must reserve a
range of consecutive ports (one for each logical node). The consecutive port
range that you reserve must be equal to the number of MLNs on the database
partition server that is running the most MLNs in your partitioned database
system. To reserve a port range for FCM to use, you need to add another
entry to the /etc/services file that specifies the end of the port range. This
entry must be of the format:
DB2_instance_name_END port_number
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number of the last port in the port range that you
reserved for database partition server communications.
For example, if you have a database partition server that is running four
database partitions, you will need to specify four consecutive ports as your
port range. In our example, the entry in the /etc/services file is:
DB2_db2inst1 60000/tcp
DB2_db2inst1_END 60003/tcp
You can add a comment that describes these entries using the #
comment identifier. For example:
DB2_db2inst1 60000/tcp # This is an EEE instance
DB2_db2inst1_END 60003/tcp # that is running 4 MLNs.
If you decide to create an /etc/hosts.equiv file, you have to create this file
on every workstation that participates in your partitioned database system.
If you want to use the INSTHOME/.rhosts file, it should contain entries similar
to the following:
workstation1.torolab.ibm.com db2inst1
workstation2.torolab.ibm.com db2inst1
switch01.torolab.ibm.com db2inst1
switch02.torolab.ibm.com db2inst1
You may want to create these links if you are developing or running
applications and want to avoid having to specify the full path to the product
libraries and include files.
To create links for the DB2 files, perform the following steps:
For more information on how to create a file system, see your Linux
documentation.
To verify that you have installed and configured DB2 EEE, perform the
following steps:
1. Log on to the system as a user with system administrative (SYSADM)
authority (by default, the username that you created for the instance
owner). For more information, see “Working with the System
Administrative Group” on page 199.
2. Enter the following command to create the SAMPLE database:
INSTHOME/sqllib/bin/db2sampl path
where:
v INSTHOME is the home directory of the instance owner.
v path is a local file system that exists on every workstation that
participates in your partitioned database system.
For example, to create the SAMPLE database on the /database file system,
enter the following command:
INSTHOME/sqllib/bin/db2sampl /database
After you have verified the installation, you can remove the SAMPLE
database to free up disk space. Enter the db2 drop database sample
command to drop the SAMPLE database.
where license_filename is the full pathname and filename for the license
file that corresponds to the product you have purchased.
For example, if the CD-ROM is mounted in the /cdrom directory and the
name of the license file is db2udbeee.lic, you would enter the following
command:
/opt/IBMdb2/V7.1/cfg/db2licm /cdrom/db2/license/db2udbeee.lic
In these instructions we assume that you use the DB2 Installer program to
install and configure DB2 Enterprise – Extended Edition (DB2 EEE). We also
assume that you install the Control Center, create an instance, and create the
Administration Server using the DB2 Installer program.
To install DB2 EEE on a cluster, you must run the DB2 Installer
program on each physical machine that you want to participate in
your partitioned database system.
Before you begin the installation, be sure that you have the following items
and information:
1. Ensure that your system meets all of the memory, hardware, and software
requirements to install your DB2 product. For more information, see
“Chapter 2. Planning for Installation” on page 17.
2. In order to run DB2 Enterprise – Extended Edition, you should update
your kernel configuration parameters and recompile the kernel:
a. Log on as root.
This showmount command should list the file systems which are
exported from the machine named fusion-en. If this command fails, the
NFS server may not have been started. Run the following command as
root on the NFS server to start the server manually:
/etc/rc.d/init.d/nfs restart
Assuming the present run level is 3, you can have this command run
automatically at boot time by renaming K20nfs to S20nfs under the
following directory: /etc/rc.d/rc3.d.
g. Ensure that the following steps were successful:
1) On a single machine in the cluster, you have created a file system
to be used as the instance and home directory.
2) If you have a configuration that uses more than one machine for a
single database instance, you have exported this file system using
NFS.
3) You have mounted the exported file system on each of the
remaining machines in the cluster.
If you are using NIS or NIS+, groups and users must be created on
the NIS server before running db2setup.
You can have the DB2 Installer create these user names, or you can create
them manually. If you want to have the DB2 Installer create the users and
groups, and you are not using NIS, skip this step, and proceed to
“Performing the Installation” on page 75.
The user names you create must conform to both the Linux naming rules,
and those of DB2. For more information on naming rules, see
“Appendix C. Naming Rules” on page 207.
If you are using NIS or NIS+, secondary groups must be created for
the DB2 instance owner and the Administration Server on the NIS
server. You must then add the primary group of the instance owner
to the secondary Administration Server group. Likewise, you must
add the primary Administration Server group to the secondary
group for the instance owner.
c. Create a user who belongs to each group that you created in the
previous step:
useradd -u 1004 -g db2adm1 -m -d /nfshome/db2inst1
db2inst1
When you use the DB2 Installer program, you should be aware of
the following:
v The DB2 Installer’s db2setup command only works with bash,
Bourne, and Korn shells. Other shells are not supported.
v Sometimes display problems can occur when running the
db2setup utility. To avoid most potential display problems, install
DB2 through a virtual console session which is a terminal window
outside of the graphical interface that most Linux distributions are
installed with.
v You can generate a trace log, db2setup.trc, to record errors
experienced during the installation. Run the db2setup command
as follows:
db2setup -d
To install DB2 EEE on a Linux system or cluster, perform the following steps:
1. Log on to the system as a user with root authority.
If you are deploying DB2 EEE on a Linux cluster, you must install
DB2 EEE on each machine.
7. When you have finished selecting the DB2 product and its components,
select OK to continue with the installation.
For more information or assistance during the installation of any DB2
product or component, select the Help option.
8. Log out.
This section describes how to create an instance using the DB2 Installer
program. We recommend that you use the DB2 Installer program to create an
instance because it configures the instance automatically for communications.
For information on how to create an instance using the db2icrt command, and
configure it for communications, see the Administration Guide and the
Installation and Configuration Supplement online document.
To create an instance using the DB2 Installer program, perform the following
steps:
1. Log on as a user with root authority on a machine where you installed
DB2 Enterprise - Extended Edition (DB2 EEE).
2. Enter the /usr/IBMdb2/V7.1/install/db2setup command to start the DB2
Installer program. The DB2 Installer window opens.
3. Select the Create option and press the Enter key.
Press the Tab key to change a highlighted option and the Enter key to
select or deselect the option you want. For more information on using the
DB2 Installer program, or for help with any task you are performing with
the DB2 Installer, select the Help option and press the Enter key.
4. Select the Create a DB2 Instance option and press the Enter key.
5. Fill in all of the fields for the username that you created for the instance
owner in “Before You Begin” on page 31.
6. Select the OK option and press the Enter key.
7. Fill in all of the fields for the username that you created to execute
fenced UDFs and stored procedures in “Before You Begin” on page 31.
8. Select the OK option and press the Enter key. You are returned to the
Create DB2 Services window.
9. Select the OK option and press the Enter key. You will receive a warning
message that you have not yet created the Administration Server; you
can ignore this message. The Summary Report window opens.
10. Select the Continue option and press the Enter key. The DB2 Installer
program will prompt you to complete this task. When you have
completed this task, you are returned to the DB2 Installer window.
11. Select the Close option and press the Enter key.
Multiple Administration Servers can be created, but there can only be one
Administration Server for each machine. If several users will be administering
your system using the Control Center, you may consider creating multiple
administration servers to distribute the network traffic. In a partitioned
database system that has one Administration Server, the Administration
Server often exists on the instance-owning node.
The db2admin commands allow you to start, stop, and configure the
Administration Server. Refer to the Command Reference for more information
about the db2admin commands.
We recommend that you use the DB2 Installer program to create the
Administration Server because it configures the Administration Server
automatically for communications. For information on how to create an
instance using the dasicrt command, and configure it for communications, see
the Administration Guide and the Installation and Configuration Supplement
online document.
To create the Administration Server using the DB2 Installer program, perform
the following steps:
Step 1. Log on as a user with root authority to a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /usr/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer window opens.
Step 3. Select the Create option and press the Enter key.
Step 4. Select the Create the Administration Server option and press the
Enter key.
Step 5. Fill in the fields for the username that you created for the
Administration Server in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key. You are returned to the
Create DB2 Services window.
Step 7. Select the OK option and press the Enter key. The Summary Report
window opens.
Step 8. Select the Continue option and press the Enter key. The DB2 Installer
program will prompt you to complete this task. When you have
completed this task, you are returned to the DB2 Installer window.
Step 9. Select the Close option and press the Enter key.
For example, when you created the DB2 instance db2inst1, on the workstation
called workstation1, the db2nodes.cfg file was updated as follows:
0 workstation1 0
If you are not using a clustered environment and want to have four database
partition servers on one physical workstation called workstation1, update the
db2nodes.cfg file as follows:
0 workstation1 0
1 workstation1 1
2 workstation1 2
3 workstation1 3
The db2nodes.cfg file is locked when the instance is running and can
only be edited when the instance is stopped.
3. Edit the db2nodes.cfg file and add an entry for each database partition
server that will participate in your partitioned database system.
4. Enter the INSTHOME/sqllib/adm/db2start command, where INSTHOME is
the home directory of the instance owner.
5. Log out.
For more information on the db2nodes.cfg file, see the Administration Guide.
Step 4. Enable the Fast Communications Manager
This section describes how to enable communication between the database
partition servers that participate in your partitioned database system.
Communication between database partition servers is handled by the Fast
Communications Manager (FCM). To enable FCM, you must ensure that the
port or port range that you reserve in the /etc/services file is available on
every workstation in your partitioned database system.
When you created a DB2 instance using the db2setup utility, an entry similar
to the following was placed in the /etc/services file:
DB2_instance_name 60000/tcp
where:
v instance_name is the name of the multipartition instance.
The port 60000 is the default FCM port used for any instance that
was created using the db2setup utility.
For example, if you created an instance called db2inst1, the entry placed in
the /etc/services file is:
DB2_db2inst1 60000/tcp
If you are planning to run multiple logical nodes (MLNs), you must reserve a
range of consecutive ports (one for each logical node). The consecutive port
range that you reserve must be equal to the number of MLNs on the database
partition server that is running the most MLNs in your partitioned database
system. To reserve a port range for FCM to use, you need to add another
entry to the /etc/services file that specifies the end of the port range. This
entry must be of the format:
DB2_instance_name_END port_number
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number of the last port in the port range that you
reserved for database partition server communications.
For example, if you have a database partition server that is running four
database partitions, you will need to specify four consecutive ports as your
port range. In our example, the entry in the /etc/services file is:
DB2_db2inst1 60000/tcp
DB2_db2inst1_END 60003/tcp
You can add a comment that describes these entries using the #
comment identifier. For example:
DB2_db2inst1 60000/tcp # This is an EEE instance
DB2_db2inst1_END 60003/tcp # that is running 4 MLNs.
If you decide to create an /etc/hosts.equiv file, you have to create this file
on every workstation that participates in your partitioned database system.
If you want to use the INSTHOME/.rhosts file, it should contain entries similar
to the following:
workstation1.torolab.ibm.com db2inst1
workstation2.torolab.ibm.com db2inst1
switch01.torolab.ibm.com db2inst1
switch02.torolab.ibm.com db2inst1
You may want to create these links if you are developing or running
applications and want to avoid having to specify the full path to the product
libraries and include files.
To create links for the DB2 files, perform the following steps:
1. Log on to each workstation as a user with root authority.
2. Enter the following command to create the links for the DB2 files:
/usr/IBMdb2/V7.1/cfg/db2ln
3. Log out.
If there are existing links to the /usr/lib and /usr/include directories from
previous versions of DB2 EEE, they will automatically be removed by
executing the db2ln command to create links for this version of DB2 EEE.
Step 8. Start the Administration Server
Before you can use the Client Configuration Assistant (CCA) or the Control
Center to administer your partitioned database system, you must ensure the
Administration Server is started and the db2cclst daemon is running on
every system in your partitioned database system.
For more information on how to create a file system, see your Linux
documentation.
To verify that you have installed and configured DB2 EEE, perform the
following steps:
1. Log on to the system as a user with system administrative (SYSADM)
authority (by default, the username that you created for the instance
owner). For more information, see “Working with the System
Administrative Group” on page 199.
2. Enter the following command to create the SAMPLE database:
INSTHOME/sqllib/bin/db2sampl path
where:
v INSTHOME is the home directory of the instance owner.
After you have verified the installation, you can remove the SAMPLE
database to free up disk space. Enter the db2 drop database sample
command to drop the SAMPLE database.
where license_filename is the full path name and file name for the license
file that corresponds to the product you have purchased.
You can also use the Control Center to manage and monitor your
DB2 licensing agreement and to monitor database usage. To manage
licensing using the Control Center, perform the following steps:
1. Start the Control Center. For more information, see “Starting the
DB2 Control Center” on page 195.
2. Click on the License Center icon from the Control Center toolbar.
The License Center opens.
3. Complete the steps to upgrade your DB2 license. For more
information, refer to the License Center’s online help by pressing
the F1 key.
We assume in these instructions that you install and configure DB2 Enterprise
- Extended Edition (DB2 EEE) using the DB2 install program, as well as create
an instance and the Administration Server using the DB2 Installer program.
If you are using NIS or NIS+, groups and users must be created on
the NIS server before running db2setup.
If you are using NIS or NIS+, secondary groups must be created for
the DB2 instance owner and the Administration Server on the NIS
server. You must then add the primary group of the instance owner
to the secondary Administration Server group. Likewise, you must
add the primary Administration Server group, to the secondary
group for the instance owner.
Step c. Create a user that belongs to each group that you created in the
previous step by entering the following commands:
useradd -g db2iadm1 -u 1004 -d /home2/db2inst1 -m db2inst1
useradd -g db2fadm1 -u 1003 -d /home2/db2fenc1 -m db2fenc1
useradd -g db2asgrp -u 1002 -d /home2/db2as -m db2as
Step d. Set an initial password for each user that you created by entering
the following commands:
passwd db2inst1
passwd db2fenc1
passwd db2as
Step e. Log out.
4. Update the Kernel Configuration Parameters. In order to run DB2 EEE you
should update your kernel configuration parameter by performing the
following steps:
msgmap 514
msgmax(1) 65535
msgmnb(1) 65535
msgmni 512
msgssz 64
msgtql 1024
msgseg(2) 32767
semmni 1024
semmap 514
semmnu 2048
semmns 2048
semume 80
shmmax(3) 2147483647
shmseg 16
shmmni 300
shm_lock_ok 1
shm_lock_uid –1
Notes:
1) The msgmax and msgmnb must be set to 65535 or larger.
2) The msgseg parameter must be set no higher than 32767.
3) The shmmax must be set to 2147483647 or larger.
To modify your PTX kernel configuration parameters, perform the following
steps:
Step 1. Log on as a user with root authority.
Step 2. Enter the menu command.
Step 3. Press A to select the System Administration option.
Step 4. Press C to select the Kernel Configuration option.
Step 5. Press Ctrl+F in the Change Kernel Configuration Disk form. If you
want to build the new kernel in a disk other than the root disk,
enter the disk and press Ctrl+F.
Step 6. In the Compile, Configure, or Remove a Kernel window, select the
kernel configuration type with which your current kernel is built
and press K.
Step 7. In the Configure a kernel with site specific parameters form, go
down one page (press Ctrl+D), press A for All in the Visibility level
for parameter changes and then press Ctrl+F.
Step 8. In the Configure Files With Adjustable Parameters window select
ALL (press Ctrl+T) and press Ctrl+F.
When you use the DB2 Installer program, you should be aware of
the following:
v The DB2 Installer’s db2setup command only works with bash,
Bourne, and Korn shells. Other shells are not supported.
v You can generate a trace log, db2setup.trc, to record errors
experienced during the installation. Run the db2setup command
as follows:
db2setup -d
Step 7. When you have finished selecting the DB2 product and its
components, select OK to continue with the installation.
For more information or assistance during the installation of any DB2
product or component, select the Help option.
Step 8. Log out.
This section describes how to create an instance using the DB2 Installer
program. We recommend that you use DB2 Installer program to create an
instance because it will configure the instance automatically for
communications.
For information on how to create an instance using the db2icrt command, and
configure it for communications, refer to the Administration Guide and the
Installation and Configuration Supplement online document.
To create an instance using the DB2 Installer program, perform the following
steps:
Step 1. Log on as a user with root authority on a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Press the Tab key to change a highlighted option and the Enter key
to select or deselect the option you want. For more information on
using the DB2 Installer program, or for help with any task you are
performing with the DB2 Installer, select the Help option and press
the Enter key.
Step 4. Select the Create a DB2 Instance option and press the Enter key.
Step 5. Fill in all of the fields for the username that you created for the
instance owner in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key.
Step 7. Fill in all of the fields for the username that you created to execute
fenced UDFs and stored procedures in “Before You Begin” on
page 31.
Step 8. Select the OK option and press the Enter key. You are returned to
the Create DB2 Services window.
Step 9. Select the OK option and press the Enter key. You will receive a
warning message that you have not yet created the Administration
Server, you can ignore this message. The Summary Report window
opens.
We recommend that you use the DB2 Installer program to create the
Administration Server because it will configure the Administration Server
automatically for communications. For information on how to create an
instance using the dasicrt command, and configure it for communications,
refer to the Administration Guide and the Installation and Configuration
Supplement online document.
To create the Administration Server using the DB2 Installer program, perform
the following steps:
Step 1. Log on as a user with root authority to a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Step 4. Select the Create the Administration Server option and press the
Enter key.
Step 5. Fill in the fields for the username that you created for the
Administration Server in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key. You are returned to the
Create DB2 Services window.
Step 7. Select the OK option and press the Enter key. The Summary Report
window opens.
Step 8. Select the Continue option and press the Enter key. The DB2 Installer
program will prompt you to complete this task. When you have
completed this task, you are returned to the DB2 Installer window.
Step 9. Select the Close option and press the Enter key.
Step 3. Update the Node Configuration File
The node configuration file (db2nodes.cfg), located in the INSTHOME/sqllib/
directory (where INSTHOME is the home directory of the instance owner)
contains configuration information for all the database partition servers that
are participating in the instance. There is a db2nodes.cfg file for every
The format of the db2nodes.cfg file is different for PTX when compared to its
format for other UNIX-based platforms. In PTX, the db2nodes.cfg can
optionally take into account the quad number that the database partition
server runs on. The format is:
nodenum hostname logical port quad netname
where:
nodenum A unique number, between 0 and 999, that identifies a
database partition server in a partitioned database system.
When you want to scale your partitioned database system,
you add an entry for each database partition server to the
db2nodes.cfgfile. The nodenum that you select for additional
database partition servers must be in ascending order,
however, gaps can exist in this sequence. You may choose to
put a gap between the nodenum values if you plan to add an
MLN and wish to keep them logically grouped together in
this file.
This entry is required.
hostname The TCP/IP hostname of the database partition server for use
by the FCM.
This entry is required.
You can specify the name of a high speed interconnect for the
hostname value. This allows the db2start, db2stop, and db2_all
commands to use the high speed interconnect for communications.
logical port Specifies the logical port number for the database partition
server. This field is used to specify a particular database
partition server on a workstation that is running MLNs. If
there is no entry for this field, the default is 0. However, if
you add an entry for the quad or netname fields, you must
enter a number for the logical port field.
If you are not using MLNs and you specify an entry for the
quad or netname fields (see below), the entry must be set to 0.
If you are using MLNs, the logical port you specify must start
at 0 and continue in ascending order with no gaps (for
example, 0,1,2).
For example, when you created the DB2 instance db2inst1, on the system
called workstation1, the db2nodes.cfg file was updated as follows:
0 workstation1 0
We recommend that you run 1 multiple logical node per quad. Typically, in a
PTX environment, you would run four database partition servers on a 4 quad
If you wanted to equally divide DB2 processing on 2 quads only, you would
update the db2nodes.cfg file as follows:
0 workstation1 0 0
1 workstation1 1 0
2 workstation1 2 1
3 workstation1 3 1
In this example, database partition servers 0 and 1 will run on quad 0 and
database partition servers 2 and 3 will run on quad 1.
Step 3. Edit the db2nodes.cfg file and add an entry for each database
partition server that will participate in your partitioned database
system.
Step 4. Enter the INSTHOME/sqllib/adm/db2start command, where
INSTHOME is the home directory of the instance owner.
Step 5. Log out.
When you created a DB2 instance using the db2setup utility, an entry similar
to the following was placed in the /etc/services file:
DB2_instance_name 60000/tcp
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number that you reserve for database partition
server communications.
The port 60000 is the default FCM port used for any instance that
was created using the db2setup utility.
For example, if you created an instance called db2inst1, the entry placed in
the /etc/services file is:
DB2_db2inst1 60000/tcp
If you are planning to run multiple logical nodes (MLNs), you must reserve a
range of consecutive ports (one for each logical node). The consecutive port
range that you reserve must be equal to the number of MLNs on the database
partition server that is running the most MLNs in your partitioned database
system. To reserve a port range for FCM to use, you need to add another
entry to the /etc/services file that specifies the end of the port range. This
entry must be of the format:
DB2_instance_name_END port_number
where:
v instance_name is the name of the multipartition instance.
For example, if you have a database partition server that is running four
database partitions, you will need to specify four consecutive ports as your
port range. In our example, the entry in the /etc/services file is:
DB2_db2inst1 60000/tcp
DB2_db2inst1_END 60003/tcp
You can add a comment that describes these entries using the #
comment identifier. For example:
DB2_db2inst1 60000/tcp # This is an EEE instance
DB2_db2inst1_END 60003/tcp # that is running 4 MLNs.
If you decide to create an /etc/hosts.equiv file, you have to create this file
on every workstation that participates in your partitioned database system.
If you want to use the INSTHOME/.rhosts file, it should contain entries similar
to the following:
workstation1.torolab.ibm.com db2inst1
workstation2.torolab.ibm.com db2inst1
switch01.torolab.ibm.com db2inst1
switch02.torolab.ibm.com db2inst1
You may want to create these links if you are developing or running
applications and want to avoid having to specify the full path to the product
libraries and include files.
To create links for the DB2 files, perform the following steps:
Step 1. Log on to each workstation as a user with root authority.
Step 2. Enter the following command to create the links for the DB2 files:
/opt/IBMdb2/V7.1/cfg/db2ln
Step 3. Log out.
Step 7. Start the Administration Server
Before you can use the Client Configuration Assistant (CCA) or the Control
Center to administer your partitioned database system, you must ensure the
Administration Server is started and the db2cclst daemon is running on
every system in your partitioned database system.
Chapter 6. Installing and Configuring DB2 Universal Database for NUMA-Q 101
db2ps | grep db2cclst
For more information on how to create a file system, see your Linux
documentation.
To verify that you have installed and configured DB2 EEE, perform the
following steps:
1. Log on to the system as a user with system administrative (SYSADM)
authority (by default, the username that you created for the instance
owner). For more information, see “Working with the System
Administrative Group” on page 199.
2. Enter the following command to create the SAMPLE database:
INSTHOME/sqllib/bin/db2sampl path
where:
v INSTHOME is the home directory of the instance owner.
After you have verified the installation, you can remove the SAMPLE
database to free up disk space. Enter the db2 drop database sample
command to drop the SAMPLE database.
where license_filename is the full pathname and filename for the license
file that corresponds to the product you have purchased.
Chapter 6. Installing and Configuring DB2 Universal Database for NUMA-Q 103
For example, if the CD-ROM is mounted in the /cdrom directory and the
name of the license file is db2udbeee.lic, you would enter the following
command:
/opt/IBMdb2/V7.1/cfg/db2licm /cdrom/db2/license/db2udbeee.lic
You can also use the Control Center to manage and monitor your
DB2 licensing agreement and to monitor database usage. To manage
licensing using the Control Center, perform the following steps:
Step 1. Start the Control Center. For more information, see “Starting
the DB2 Control Center” on page 195.
Step 2. Click on the License Center icon from the Control Center
toolbar. The License Center opens.
Step 3. Complete the steps to upgrade your DB2 license. For more
information, refer to the License Center’s online help by
pressing the F1 key.
We assume in these instructions that you install and configure DB2 Enterprise
- Extended Edition (DB2 EEE) using the DB2 Installer program. We also
assume that you select to install the Control Center, create an instance, and
create the Administration Server using the DB2 Installer program.
If you want to install your DB2 product using your UNIX operating system’s
native installation tools, refer to the Installation and Configuration Supplement.
If you are installing DB2 EEE on a cluster, and you are not running
cluster software, you will have to run the DB2 Installer program on
each physical machine that you want to participate in your
partitioned database system.
If you are running SunCluster 2.2, you can use ctelnet or cconsole
to perform your installation. For more information, see your product
documentation.
Before you begin the installation, be sure that you have the following items
and information:
1. Ensure that your system meets all of the memory, hardware, and software
requirements to install your DB2 product. For more information, see
“Chapter 2. Planning for Installation” on page 17.
Step a. On one machine, select a disk partition or configure one using the
format command. When using the format command, ensure that
the disk partitions being used do not overlap. Overlapping
partitions can cause data corruption or file system failures.
Step b. Using a utility like newfs or mkfs, create a file system on this
partition. The file system should be large enough to contain the
necessary DB2 files as well as other non-DB2 files. A minimum of
300 MB is recommended.
Step c. Locally mount the file system you have just created and add an
entry to the /etc/vfstab file so that this file system is mounted
each time the system is rebooted. For example:
dev/dsk/c1t0d2s2 /dev/rdsk/c1t0d2s2 /nfshome ufs 2 yes -
You should not mount this file system using the automounter utility.
This utility can cause NFS mounting or locking problems in a
partitioned database system.
This showmount command should list the file systems which are
exported from the machine named fusion-en. If this command
fails, the NFS server may not have been started. To start the server
manually, run the following commands as root on the NFS server:
/usr/lib/nfs/mountd
/usr/lib/nfs/nfsd -a 16
If you are using NIS or NIS+, groups and users must be created on
the NIS server before running db2setup.
You can have the DB2 Installer create these user names, or you can create
them manually. The user names you create must conform to both your
operating system’s naming rules, and those of DB2. For more information
on naming rules, see “Appendix C. Naming Rules” on page 207.
If you are using NIS or NIS+, secondary groups must be created for
the DB2 instance owner and the Administration Server on the NIS
server. You must then add the primary group of the instance owner
to the secondary Administration Server group. Likewise, you must
add the primary Administration Server group, to the secondary
group for the instance owner.
Step c. Create a user that belongs to each group that you created in the
previous step by entering the following commands:
useradd -g db2iadm1 -u 1004 -d /nfshome/db2inst1 -m db2inst1
useradd -g db2fadm1 -u 1003 -d /nfshome/db2fenc1 -m db2fenc1
useradd -g db2asgrp -u 1002 -d /nfshome/db2as -m db2as
Step d. Set an initial password for each user that you created by entering
the following commands:
Notes:
1) The msgsys:msginfo_msgmnb and msgsys:msginfo_msgmax
parameters must be set to 65535 or larger.
2) The msgsys:msgseg parameter must be set no higher than
32767.
3) The shmsys:shminfo_shmmax parameters should be set to the
suggested value in the above table, or 90% of the physical
memory (in bytes), whichever is higher. For example, if you
have 196 MB of physical memory in your system, set the
shmsys:shminfo_shmmax parameter to 184968806
(196*1024*1024*0.9).
When you use the DB2 Installer program, you should be aware of
the following:
v The DB2 Installer’s db2setup command only works with bash,
Bourne, and Korn shells. Other shells are not supported.
v You can generate a trace log, db2setup.trc, to record errors
experienced during the installation. Run the db2setup command
as follows:
db2setup -d
If you are installing DB2 EEE on a Solaris cluster, you must log on to
each system and install this product, or use the cconsole or ctelnet
utilities.
Step 2. If the Volume Manager (vold) is not running, enter the following
commands to mount the CD-ROM:
mkdir -p /cdrom/unamed_cdrom
mount -F hsfs -o ro /dev/dsk/c0t6d0s2 /cdrom/unamed_cdrom
Step 7. When you have finished selecting the DB2 product and its
components, select OK to continue with the installation.
For more information or assistance during the installation of any DB2
product or component, select the Help option.
Step 8. Log out.
For information on how to create an instance using the db2icrt command, and
configure it for communications, refer to the Administration Guide and the
Installation and Configuration Supplement online document.
To create an instance using the DB2 Installer program, perform the following
steps:
Step 1. Log on as a user with root authority on a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Press the Tab key to change a highlighted option and the Enter key
to select or deselect the option you want. For more information on
using the DB2 Installer program, or for help with any task you are
performing with the DB2 Installer, select the Help option and press
the Enter key.
Step 4. Select the Create a DB2 Instance option and press the Enter key.
Step 5. Fill in all of the fields for the username that you created for the
instance owner in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key.
Step 7. Fill in all of the fields for the username that you created to execute
fenced UDFs and stored procedures in “Before You Begin” on
page 31.
Step 8. Select the OK option and press the Enter key. You are returned to
the Create DB2 Services window.
Step 9. Select the OK option and press the Enter key. You will receive a
warning message that you have not yet created the Administration
Server; you can ignore this message. The Summary Report window
opens.
Step 10. Select the Continue option and press the Enter key. The DB2
Installer program will prompt you to complete this task. When you
have completed this task, you are returned to the DB2 Installer
window.
Step 11. Select the Close option and press the Enter key.
We recommend that you use the DB2 Installer program to create the
Administration Server because it will configure the Administration Server
automatically for communications. For information on how to create an
instance using the dasicrt command, and configure it for communications,
refer to the Administration Guide and the Installation and Configuration
Supplement online document.
To create the Administration Server using the DB2 Installer program, perform
the following steps:
Step 1. Log on as a user with root authority to a machine where you
installed DB2 Enterprise - Extended Edition (DB2 EEE).
Step 2. Enter the /opt/IBMdb2/V7.1/install/db2setup command to start the
DB2 Installer program. The DB2 Installer windows opens.
Step 3. Select the Create option and press the Enter key.
Step 4. Select the Create the Administration Server option and press the
Enter key.
Step 5. Fill in the fields for the username that you created for the
Administration Server in “Before You Begin” on page 31.
Step 6. Select the OK option and press the Enter key. You are returned to the
Create DB2 Services window.
Step 7. Select the OK option and press the Enter key. The Summary Report
window opens.
Step 8. Select the Continue option and press the Enter key. The DB2 Installer
program will prompt you to complete this task. When you have
completed this task, you are returned to the DB2 Installer window.
Step 9. Select the Close option and press the Enter key.
Step 3. Update the Node Configuration File
The node configuration file (db2nodes.cfg), located in the INSTHOME/sqllib/
directory (where INSTHOME is the home directory of the instance owner)
contains configuration information for all the database partition servers that
are participating in the instance. There is a db2nodes.cfg file for every
multipartition instance. This file contains one entry for each database partition
server for a particular DB2 instance. By default, when you create an instance,
the db2nodes.cfg file is automatically created and an entry for the workstation
where the instance was created is added to the file.
For example, when you created the DB2 instance db2inst1, on the workstation
called workstation1, the db2nodes.cfg file was updated as follows:
0 workstation1 0
If you are not using a clustered environment and want to have four database
partition servers on one physical workstation called workstation1, update the
db2nodes.cfg file as follows:
0 workstation1 0
1 workstation1 1
2 workstation1 2
3 workstation1 3
3. Edit the db2nodes.cfg file and add an entry for each database partition
server that will participate in your partitioned database system.
4. Enter the INSTHOME/sqllib/adm/db2start command, where INSTHOME is
the home directory of the instance owner.
5. Log out.
For more information on the db2nodes.cfg file, see the Administration Guide.
Step 4. Enable the Fast Communications Manager
This section describes how to enable communication between the database
partition servers that participate in your partitioned database system.
Communication between database partition servers is handled by the Fast
Communications Manager (FCM). To enable FCM, you must ensure that the
port or port range that you reserve in the /etc/services file is available on
every workstation in your partitioned database system.
When you created a DB2 instance using the db2setup utility, an entry similar
to the following was placed in the /etc/services file:
DB2_instance_name 60000/tcp
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number that you reserve for database partition
server communications.
The port 60000 is the default FCM port used for any instance that
was created using the db2setup utility.
For example, if you created an instance called db2inst1, the entry placed in
the /etc/services file is:
DB2_db2inst1 60000/tcp
If you are planning to run multiple logical nodes (MLNs), you must reserve a
range of consecutive ports (one for each logical node). The consecutive port
where:
v instance_name is the name of the multipartition instance.
v port_number is the port number of the last port in the port range that you
reserved for database partition server communications.
For example, if you have a database partition server that is running four
database partitions, you will need to specify four consecutive ports as your
port range. In our example, the entry in the /etc/services file is:
DB2_db2inst1 60000/tcp
DB2_db2inst1_END 60003/tcp
You can add a comment that describes these entries using the #
comment identifier. For example:
DB2_db2inst1 60000/tcp # This is an EEE instance
DB2_db2inst1_END 60003/tcp # that is running 4 MLNs.
We recommend that the paging space available be equal to two and a half
to three times the amount of physical memory installed on your
workstation, the minimum being one GB.
Step 6. Enable the Execution of Remote Commands
In a multipartition instance, each database partition server must have the
authority to perform remote commands on all the other database partition
servers in the partitioned database system. To do this, you can either create an
INSTHOME/.rhosts file (where INSTHOME is the home directory of the
instance owner) or an /etc/hosts.equiv file.
If you decide to create an /etc/hosts.equiv file, you have to create this file
on every workstation that participates in your partitioned database system.
If you want to use the INSTHOME/.rhosts file, it should contain entries similar
to the following:
workstation1.torolab.ibm.com db2inst1
workstation2.torolab.ibm.com db2inst1
switch01.torolab.ibm.com db2inst1
switch02.torolab.ibm.com db2inst1
You may want to create these links if you are developing or running
applications and want to avoid having to specify the full path to the product
libraries and include files.
To create links for the DB2 files, perform the following steps:
Step 1. Log on to each workstation as a user with root authority.
Step 2. Enter the following command to create the links for the DB2 files:
/opt/IBMdb2/V7.1/cfg/db2ln
Step 3. Log out.
For more information on how to create a file system, see your Linux
documentation.
To verify that you have installed and configured DB2 EEE, perform the
following steps:
1. Log on to the system as a user with system administrative (SYSADM)
authority (by default, the username that you created for the instance
owner). For more information, see “Working with the System
Administrative Group” on page 199.
2. Enter the following command to create the SAMPLE database:
INSTHOME/sqllib/bin/db2sampl path
where:
v INSTHOME is the home directory of the instance owner.
v path is a local file system that exists on every workstation that
participates in your partitioned database system.
For example, to create the SAMPLE database on the /database file system,
enter the following command:
INSTHOME/sqllib/bin/db2sampl /database
After you have verified the installation, you can remove the SAMPLE
database to free up disk space. Enter the db2 drop database sample
command to drop the SAMPLE database.
where license_filename is the full pathname and filename for the license
file that corresponds to the product you have purchased.
For example, if the CD-ROM is mounted in the /cdrom directory and the
name of the license file is db2udbeee.lic, you would enter the following
command:
/opt/IBMdb2/V7.1/cfg/db2licm /cdrom/db2/license/db2udbeee.lic
You can skip this chapter if you are not migrating instances and databases.
The procedures in this chapter assume that you have performed the
pre-installation migration tasks described in “Chapter 2. Planning for
Installation” on page 17.
Migrating Instances
To migrate instances, including your Administration Server instance, to a
format usable by DB2 Version 7, you must run the db2imigr command:
1. Log in as user with root authority.
2. Run the db2imigr command as follows:
DB2DIR/instance/db2imigr [-d] [-u fencedID] InstName
and where:
-d Sets the debug mode that you can use for problem determination.
This parameter is optional.
-u fencedID
Is the user under which the fenced user-defined functions (UDFs)
and stored procedures will execute. This parameter is optional
only when a DB2 Run-Time Client is installed. It is required for all
other DB2 products.
InstName
Is the login name of the instance owner.
Note: If you are migrating a DB2 for AIX instance and the it uses the
environment variable DB2SORT set to the keyword SMARTSORT, you
must set the registry value db2sort after the instance is migrated to
Version 7. Set the db2sort registry value to the run time library for the
sort command as follows:
db2set DB2SORT="/usr/lib/libsort.a"
Migrating Databases
This section applies only if you are migrating databases from Version 5.x to
the Version 7.1 format. If you are migrating from Version 6.1 to Version 7.1,
you can skip this section.
R RS
USER username
USING password
Note: This section applies only to migration scenarios involving Version 5.x
databases, or to Version 6 databases that were previously migrated
from the Version 5.x format but whose unique indexes were not
migrated using the db2uiddl command.
All existing applications will continue to work even if the unique indexes
are not converted to Version 7 semantics. You have to convert unique
indexes to Version 7 semantics only if support for deferred uniqueness
checking is required.
where:
– dbname represents the database name. This parameter is required.
– explain_schema represents the schema name of the explain tables to be
migrated. This parameter is required.
– userid and password represent the current user’s ID and password. These
parameters are optional.
Refer to “Appendix E. Using the DB2 Library” on page 237 for more
information about the DB2 product library.
Note: DB2 clients can connect to DB2 servers two releases later or one release
earlier than the client’s release level, as well as to servers at the same
release level. For example, a DB2 Version 5.2 client can connect to DB2
Version 5.0, 5.2, 6.1, and 7.1 servers, while a DB2 Version 7.1 client can
connect to DB2 Version 6.1 and 7.1 servers.
You may install a DB2 client on any number of workstations. For information
about licensing, refer to your License Information Booklet.
You cannot create a database on a DB2 client, only connect to databases that
reside on a DB2 server.
DB2 Run-Time Clients are available for the following platforms: AIX, HP-UX,
Linux, OS/2, NUMA-Q, Silicon Graphics IRIX, the Solaris Operating
Environment, and Windows 32-bit operating systems.
The DB2 Administration Client also includes the client components for DB2
Query Patroller, a sophisticated query management and workload distribution
tool. In order to use Query Patroller, you must have a Query Patroller server
installed. For more information refer to the DB2 Query Patroller Installation
Guide.
DB2 Administration Clients are available for the following platforms: AIX,
HP-UX, Linux, OS/2, Solaris, Windows 32-bit operating systems.
Distributed Installation
If you are planning to install DB2 products across your network, you may
consider using a distributed installation. With a network-based installation,
you can roll out multiple identical copies of DB2 products. For more
information on performing a distributed installation, refer to the Installation
and Configuration Supplement.
Installation Steps
To install a DB2 client, perform the following steps:
Step 1. Log on to the system with the user account that you want to use to
perform the installation.
Step 2. Shut down any other programs so that the setup program can update
files as required.
Step 3. Insert the appropriate CD-ROM into the drive. The auto-run feature
automatically starts the setup program. The setup program will
determine the system language, and launch the setup program for
that language. If you want to run the setup program in a different
language, or the setup program failed to start, see the following tip:
where:
v x: represents your CD-ROM drive
v language represents the country code for your language (for
example, EN for English). Table 18 on page 206 lists the code
for each available language.
c. Click OK.
Step 5. From this window, you can view the Installation Prerequisites and
the Release Notes, you can take a Quick Tour to explore the features,
capabilities, and benefits of DB2 Universal Database Version 7, or you
can proceed directly to the installation.
Once you have initiated the installation, proceed by following the
setup program’s prompts. Online help is available to guide you
through the remaining steps. Invoke the online help by clicking Help,
or by pressing F1 at any time. You can click Cancel at any time to
end the installation.
Chapter 11. Installing DB2 Clients on Windows 32-Bit Operating Systems 143
To configure your client to access remote servers, go to “Chapter 15.
Configuring Client-to-Server Communications Using the Client
Configuration Assistant” on page 171.
If you want to run Windows 3.x applications on your OS/2 system, you must
also install the DB2 Client Application Enabler for Windows 3.x on your
system. For more information, connect to the IBM DB2 Client Application
Enabler Web site at
http://www.ibm.com/software/data/db2/db2tech/clientpak.html
Installation Steps
To install a DB2 client for OS/2, perform the following steps:
Step 1. Insert the appropriate CD-ROM into the drive.
Step 4. From this window, you can view the installation prerequisites and
the release notes, you can take a Quick Tour to explore the features,
capabilities, and benefits of DB2 Universal Database Version 7, or you
can proceed directly to the installation.
Once you have initiated the installation, proceed by following the install
program’s prompts. Online help is available to guide you through the
remaining steps. To invoke the online help, click Help, or press F1.
The db2setup utility can generate a trace log to record errors during
installation. To generate a trace log, run the ./db2setup -d command. This
generates a log in /tmp/db2setup.trc.
The db2setup utility works with Bash, Bourne, and Korn shells. Other shells
are not supported.
If you are installing a DB2 client on AIX, Linux, or SGI IRIX systems, go to
“Installing Your DB2 Client” on page 153.
Before installing your DB2 client on a HP-UX, PTX or Solaris system, you may
need to update your system’s kernel configuration parameters. We
recommend that you set your system’s kernel configuration parameters to the
values in the following sections:
v “HP-UX Kernel Configuration Parameters”
v “NUMA-Q/PTX Kernel Configuration Parameters” on page 151
v “Solaris Kernel Configuration Parameters” on page 152
HP-UX Kernel Configuration Parameters
Table 10 lists the recommended values for HP-UX kernel configuration
parameters. These values are valid for DB2 clients running on HP-UX Version
11.
Note: You must reboot your machine after updating any kernel configuration
parameters.
Table 10. HP-UX Kernel Configuration Parameters (Recommended Values)
Kernel Parameter Recommended Value
msgseg 8192
msgmnb 65535 (1)
msgmax 65535 (1)
msgssz 16
Notes:
1. Parameters msgmnb and msgmax must be set to 65535 or higher.
2. To maintain the interdependency among kernel parameters, change
parameters in the same sequence in which they appear in Table 10.
After you have updated your kernel parameters, go to “Installing Your DB2
Client” on page 153 to continue with the installation.
NUMA-Q/PTX Kernel Configuration Parameters
Table 11 lists the recommended values for NUMA-Q/PTX kernel configuration
parameters for DB2 clients.
Note: You must reboot your machine after updating any kernel configuration
parameters.
Table 11. NUMA-Q/PTX Kernel Configuration Parameters (Recommended Values)
Kernel Parameter Recommended Value
msgmax 65535
msgmnb 65535
msgseg 8192
msgssz 16
After you have updated your kernel parameters, go to “Installing Your DB2
Client” on page 153 to continue with the installation.
Solaris Kernel Configuration Parameters
Table 12 lists the recommended values for Solaris kernel configuration
parameters.
Note: You must reboot your machine after updating any kernel configuration
parameters.
Table 12. Solaris Kernel Configuration Parameters (Recommended Values)
Kernel Parameter Recommended Value
Notes:
1. Parameters msgsys:msginfo_msgmnb and msgsys:msginfo_msgmax must be
set to 65535 or higher.
To set a kernel parameter, add a line at the end of the /etc/system file as
follows:
After you have updated your kernel parameters, go to “Installing Your DB2
Client” to continue with the installation.
If you are installing a DB2 client from a remote server, it is better to use the
telnet command to open a telnet session instead of using the rlogin command
to connect to your remote server.
You can use the db2setup program add additional products or components
after your initial installation. To create or add additional DB2 products and
components, enter the following command:
On AIX
/usr/lpp/db2_07_01/install/db2setup
On HP-UX, PTX, SGI IRIX, or Solaris
/opt/IBMdb2/V7.1/install/db2setup
On Linux
/usr/IBMdb2/V7.1/install/db2setup
The Control Center is the main DB2 graphical tool for administering your
database. It is available on Windows 32-bit, OS/2, and UNIX operating
systems.
The Control Center provides a clear overview of all the systems and database
objects being managed. You can also access other administration tools from
the Control Center by selecting icons on the Control Center toolbar or from
the Tools pop-up menu.
Note: Some operating systems, including OS/2 Warp Server for e-business
and AIX 4.3, have built-in Java support. For more information, check
with your administrator.
v Java applets are programs that run within Java-enabled browsers. The
Control Center applet code can reside on a remote machine and is served to
the client’s browser through a web server. This type of client is often called
a thin client because a minimal amount of resources (a Java-enabled
browser) is required to run the Java applet.
Machine Configurations
You can set up your Control Center in a number of different ways. The
following table identifies four scenarios, each showing a different way of
installing the required components. These scenarios are referenced throughout
the Control Center Services Setup (Applet Mode only) section that follows the
table.
Table 13. Control Center Machine Configuration Scenarios
Scenario Machine A Machine B Machine C
1 - Stand-alone, JRE
Application Control Center application
DB2 server
2 - Two Tier, Application JRE DB2 server
Control Center application
DB2 client
3 - Two Tier, Browser Supported Browser Web server
(Windows and OS/2 only) JDBC Applet Server
Control Center applet DB2 server
4 - Three Tier, Browser Supported Browser JDBC Applet Server DB2 server
(Windows and OS/2 only) DB2 client
Control Center applet
Figure 4 on page 157 summarizes the four basic Control Center machine
configurations:
DB2 JDBC
Applet Server
JRE
CC Java
Application
DB2 UDB
Client
Single Machine
DB2 Server
We recommend that you start the Control Center JDBC Applet Server with a
user account that has SYSADM authority.
The first time you start the Control Center JDBC Applet Server, it will create
several node directory entries, together with various files for administration
purposes. In Scenarios 1 and 3 in “Machine Configurations” on page 156, all
of these administration files and directory entries will be created in the
current DB2 instance.
Most DB2 resources are accessed over database connect or instance attach. In
both cases the user must supply valid user ID and password combinations to
gain access. However, some resources are accessed directly by the Control
Center JDBC Applet Server, including the database and node directories
(catalogs), and the Command Line Processor. Access to these resources is
On Windows NT, you can start the Control Center JDBC Applet Server by
clicking Start and selecting Settings —> Control Panel —> Services. Select
the DB2 JDBC Applet Server - Control Center service and click Start.
On Windows 2000, you can start the Control Center JDBC Applet Server by
clicking Start and selecting Settings —> Control Panel —> Administrative
Tools —> Services. Select the DB2 JDBC Applet Server - Control Center
service, click the Action menu and then select Start.
On any system, you can start the Control Center JDBC Applet Server by
entering:
net start DB2ControlCenterServer
This step is not required if your Control Center JDBC Applet Server is
autostarted.
On Windows 2000, click Start and select Settings —> Control Panel —>
Administrative Tools —> Services.
If the DB2 Security Server is not started on Windows NT, select it and click
Start. On Windows 2000, select the Action menu and click Start.
If you choose to use a virtual directory, substitute this directory for the home
directory. For example, if you map sqllib to a virtual directory called temp on
a server named yourserver, a client would use the URL:
http://yourserver/temp
If you do not have the DB2 documentation installed and you would like to
configure your web server to work with DB2’s online documentation, refer to
the Installation and Configuration Supplement.
To load the Control Center HTML page, perform the following steps:
1. Start the Control Center Launch page through your web server. In your
browser, select File –> Open Page. The Open Page dialog box appears.
Enter the URL of your Web server and the main Control Center page and
click on the Open push button. For example, if your server is named
yourserver, you would open http://yourserver/cc/prime/db2cc.htm
2. In the Server port field, enter a value for the Control Center JDBC Applet
Server port. The default server port value is 6790.
3. Click on the Start Control Center push button.
4. The Control Center Sign On window opens. Enter your user ID and
password. This user ID must have an account on the machine that is
running the Control Center JDBC Applet Server. Your initial logon will be
used for all database connections. It can be changed from the Control
Center pull-down menu. A unique user profile will be assigned to each
user ID. Click OK.
5. The DB2 Control Center window opens.
6. You can start working with the Control Center without an existing
database by creating a sample database. Enter the db2sampl command on
the DB2 Universal Database server. On UNIX operating systems, ensure
that you are logged in to the DB2 instance before you enter the db2sampl
command.
to
param name="autoStartCC" value="true"
v For Scenarios 3 or 4, modify the autoStartCC, hostNameText, and
portNumberText parameter tags in db2cc.htm to
param name="autoStartCC" value="true"
param name="hostNameText" value="yourserver"
param name="portNumberText" value="6790"
Functional Considerations
If you are using the Control Center over the Internet, be aware that there is no
encryption of the data flow between the Control Center JDBC Applet Server
and the browser.
To use the color options of Visual Explain on Netscape, you must set your
operating system to support more than 256 colors.
When you are using the Control Center under Scenarios 3 or 4, the local
system is Machine B. The local system is the system name as it appears in the
DB2 Control Center window.
Troubleshooting Information
For the latest service information on the Control Center, point your browser to
http://www.ibm.com/software/data/db2/udb/db2cc
Ifyou are having problems running the Control Center, check the following:
v Ensure the Control Center JDBC Applet Server (db2jd) is running.
v Verify that the server port number is correct.
v Check that the Control Center JDBC Applet Server is running under a user
account that has SYSADM authority.
v Ensure that the Database Administration Server (DAS) is running on any
DB2 Universal Database systems you are trying to administer by entering
the db2admin start command. On UNIX-based systems, ensure that you are
logged in as the DAS instance owner when you issue this command.
If you are having problems running the Control Center as an application, also
check the following:
If you are having problems running the Control Center as an applet, also check
the following:
v Verify that you are running a supported browser. See Table 14 on page 157
for more information.
v Check your browser’s Java console window for diagnostic and trace
information for the Control Center.
v Make sure that the client browser does not have CLASSPATH set. To make
sure CLASSPATH is not set, open a command window and enter SET
CLASSPATH= then start your client browser from this command window.
Also, note that if CLASSPATH is not set in a Windows NT or Windows
2000 environment, it may still get picked up from autoexec.bat from a
Windows 9x installation on the same machine.
v Ensure that you are using the db2cc.htm file from the machine running the
Control Center JDBC Applet Server.
v Remember that the Control Center works within the DB2 client’s locale, and
that the DB2 client is located at the Control Center JDBC Applet Server’s
location.
Administering DB2 for OS/390 and DB2 Connect Enterprise Edition servers with
the Control Center
The Control Center has been greatly enhanced to deliver new management
functions to database administrators who need to manage DB2 for OS/390
V5.1 and later database servers.
The Control Center has also been enhanced to manage operational and
performance characteristics of DB2 Connect Enterprise Edition connectivity
servers. The combination of DB2 for OS/390 server management and new
DB2 Connect monitoring support provide complete end-to-end administration
and monitoring for desktop and web applications that work with DB2 for
OS/390 servers.
The DB2 Control Center uses the familiar ″explorer″ interface to allow
database administrators to easily navigate between different database servers
and the database objects they manage. Context sensitive right-mouse activated
menus provide administrators with the ability to change attributes of database
objects and to launch commands and utilities.
Database objects are presented in a consistent fashion for all DB2 family
servers. This greatly reduces the amount of learning that is required for
administrators who need to manage both DB2 for OS/390 and DB2 Universal
Databases on Windows NT, Windows 2000, UNIX and OS/2 servers. While
Administrators can also collect load and performance information such as the
number of SQL statements and transactions executed, number of bytes sent
and received, statement and transaction execution times and much more.
Collected data can be displayed using easy to understand live graphs.
Preparing DB2 for OS/390 Servers for the Control Center
The DB2 Control Center uses stored procedures to deliver many of its
management functions. Therefore, for the Control Center to function properly
each DB2 for OS/390 server that will be managed from the Control Center
needs to have stored procedures enabled and the proper stored procedures
installed on that server.
Once the Control Center is running, start by clicking on the plus sign next to
the server you want to administer. Select the database or connectivity server
objects that you want to administer and right click on the object to work with
object properties or to execute actions on the object. You can invoke the online
help by clicking Help, or by pressing F1 at any time.
Other Sources of Information
For more information about using the Control Center to administer DB2 for
OS/390, refer to the following online resource:
http://www.ibm.com/software/data/db2/os390/v6facts/db2cc.html
For complete information about DB2 for OS/390 Version 6, refer to the online
library: http://www.ibm.com/software/data/db2/os390/v6books.html
You may still want to use the CCA in the LDAP environment to:
v Manually catalog a database in the LDAP directory
v Register a database as an ODBC data source
v Configure CLI/ODBC information
v Remove a database cataloged in the LDAP directory
For more information about the LDAP Directory Support, refer to the
Installation and Configuration Supplement.
To complete the steps in this section, you should be familiar with how to start
the CCA. For more information, see “Starting the Client Configuration
Assistant” on page 195.
If you have added a new protocol to your network that is not detectable, or
want to modify any of the default settings, refer to the Installation and
Configuration Supplement.
If you are adding a host or AS/400 database, refer to the ″Configuring DB2
Connect to Host or AS/400 Communications Using the Client Configuration
Assistant″ section in your DB2 Connect Quick Beginnings manual.
Configuration Steps
To configure your workstation to access a database on a remote server,
perform the following steps:
Step 1. Log on to the system with a valid DB2 user ID. For more
information, see “Appendix C. Naming Rules” on page 207.
Step 2. Start the CCA. For more information, see “Starting the Client
Configuration Assistant” on page 195.
The Welcome window opens each time you start the CCA, until you
add at least one database to your client.
Step 3. Click on the Add push button to configure a connection.
You can use one of the following configuration methods:
v “Adding a Database Using a Profile” on page 173.
v “Adding a Database Using Discovery” on page 174.
v “Adding a Database Manually” on page 176.
Chapter 15. Configuring Client-to-Server Communications Using the Client Configuration Assistant 173
If the connection test failed, you will receive a help message. To
change any settings you may have incorrectly specified, click the
Change push button in the Confirmation window to return to the
Add Database Wizard. If problems persist, refer to the Troubleshooting
Guide for more information.
Step 7. You are now able to use this database. Click Add to add more
databases, or click Close to exit the Add Database Wizard. Click
Close again to exit the CCA.
Adding a Database Using Discovery
This option cannot return information about DB2 systems earlier
than Version 5 or any systems where an Administration Server is not
running. For more information, refer to the Administration Guide.
You can use the Discovery feature to search a network for databases. To add a
database to your system using Discovery, perform the following steps:
Step 1. Select the Search the network radio button and click the Next push
button.
Step 2. Click the [+] sign beside the Known Systems icon to list all the
systems known to your client.
Step 3. Click the [+] sign beside a system to get a list of the instances and
databases on it. Select the database that you want to add, click the
Next push button, and proceed to Step 4.
If the system that contains the database that you want to add is not
listed, perform the following steps:
a. Click on the [+] sign beside the Other Systems (Search the
network) icon to search the network for additional systems.
b. Click on the [+] sign beside a system to get a list of the instances
and databases on it.
c. Select the database that you want to add, click Next, and proceed
to Step 4.
If the system that you want to add is still not listed, it can be added
to the list of systems by performing the following steps:
a. Click Add System. The Add System window opens.
b. Enter the required communication protocol parameters for the
remote Administration Server and click OK. A new system is
added. For more information, click Help.
c. Select the database that you want to add and click Next.
Step 4. Enter a local database alias name in the Database alias field and
optionally enter a comment that describes this database in the
Comment field. Click Next.
Step 5. If you are planning to use ODBC, register this database as an ODBC
data source.
Chapter 15. Configuring Client-to-Server Communications Using the Client Configuration Assistant 175
v If you would like to create an ODBC data source file to share
database access, select the As a file data source radio button
and enter the path and file name for this file in the File data
source name field.
c. Click the Optimize for application drop down box and select the
application for which you want to tune the ODBC settings.
d. Click Finish to add the database that you selected. The
Confirmation window opens.
Step 6. Click the Test Connection push button to test the connection. The
Connect to DB2 Database window opens.
Step 7. In the Connect To DB2 Database window, enter a valid user ID and
password for the remote database and click OK. If the connection is
successful, a message confirming the connection appears.
If the connection test failed, you will receive a help message. To
change any settings you may have incorrectly specified, click the
Change push button in the Confirmation window to return to the
Add Database Wizard. If problems persist, refer to the Troubleshooting
Guide for more information.
Step 8. You are now able to use this database. Click Add to add more
databases, or click Close to exit the Add Database Wizard. Click
Close again to exit the CCA.
Adding a Database Manually
If you have the information for the database you want to connect to and the
server upon which it resides, you can manually enter all of the configuration
information. This method is analogous to entering commands via the
command line processor, however, the parameters are presented graphically
for you.
Chapter 15. Configuring Client-to-Server Communications Using the Client Configuration Assistant 177
Step 7. Click the Test Connection push button to test the connection. The
Connect to DB2 Database window opens.
Step 8. In the Connect To DB2 Database window, enter a valid user ID and
password for the remote database and click OK. If the connection is
successful, a message confirming the connection appears.
If the connection test failed, you will receive a help message. To
change any settings you may have incorrectly specified, click the
Change push button in the Confirmation window to return to the
Add Database Wizard. If problems persist, refer to the Troubleshooting
Guide for more information.
Step 9. You are now able to use this database. Click Add to add more
databases, or click Close to exit the Add Database Wizard. Click
Close again to exit the CCA.
You can use the Export function of the CCA to create a client profile for an
existing client configuration and use it to create identical target clients across
your network. A client profile contains database connection, ODBC/CLI, and
configuration information for an existing client. Use the CCA Import function
to set up multiple clients across your network. Each target client will have the
same configuration and settings as the existing client. For more information
on creating and using client profiles, see “Creating and Using Profiles”.
You have now completed all the tasks that are involved in Quick
Beginnings and are ready to start using DB2 Universal Database.
We recommend that you create a server profile only after you have
created the DB2 databases that you want your remote clients to
access.
You are ready to use this profile on your system. For more information
on how to add a database to your system using a server profile, go to
“Configuration Steps” on page 172.
Client Profiles
Information in a client profile can be used to configure clients using the
Import function in the Client Configuration Assistant (CCA). Clients can
import all or a subset of the configuration information in a profile. The
following scenario assumes that the database connections configured on one
client will be exported and used to set up one or more clients.
A client profile is generated from a client using the Export function of the
CCA. The information contained in a client profile is determined during the
export process. Depending on the settings chosen, it can contain the existing
client’s:
v Database connection information (including CLI or ODBC settings).
v Client settings (including database manager configuration parameters and
DB2 registry variables).
v CLI or ODBC common parameters.
v Configuration data for the local APPC or NetBIOS communications
subsystem.
Chapter 15. Configuring Client-to-Server Communications Using the Client Configuration Assistant 179
v If you want to create a profile that contains all of the databases
cataloged on your system, and all of the configuration information
for this client, select the All radio button, click OK, and go to Step
8.
v If you want to create a profile that contains all of the databases
cataloged on your system without any of the configuration
information for this client, select the Database connection
information radio button, click OK, and go to Step 8.
v If you want to select a subset of the databases that are cataloged
on your system, or a subset of the configuration information for
this client, select the Customize radio button, click OK, and go to
the next step.
Step 4. Select the databases to be exported from the Available databases box
and add them to the Selected databases box by clicking on the push
button.
Step 5. Select the check boxes from the Select custom export option box that
correspond to the options that you want to set up for the target
client.
To customize settings, click on the appropriate Customize push
button. The settings that you customize will only affect the profile to
be exported, no changes will be made to your workstation. For more
information, click Help.
Step 6. Click OK. The Export Client Profile window opens.
Step 7. Enter a path and file name for this client profile and click OK. The
DB2 Message window appears.
Step 8. Click OK.
If you selected the All radio button, you are now ready to start using
your DB2 product. For more advanced topics, refer to the Administration
Guide and the Installation and Configuration Supplement.
Step 6. You are presented with a list of systems, instances, and databases.
Select the database that you want to add and click Next.
Step 7. Enter a local database alias name in the Database alias field and
optionally enter a comment that describes this database in the
Comment field. Click Next.
Step 8. If you are planning to use ODBC, register this database as an ODBC
data source.
Chapter 15. Configuring Client-to-Server Communications Using the Client Configuration Assistant 181
Add Database Wizard. If problems persist, refer to the
Troubleshooting Guide for more information.
Step 11. You are now able to use this database. Click Add to add more
databases, or click Close to exit the Add Database Wizard. Click
Close again to exit the CCA.
If you have added a new protocol to your network, or want to change any of
the default settings on the server, refer to the Installation and Configuration
Supplement.
Chapter 16. Configuring Client-to-Server Communications Using the Command Line Processor 185
The client must know the IP address of the server to which it is attempting to
establish communications. If a name server does not exist on your network,
you may directly specify a hostname that maps to the IP address (ip_address)
of the server in the local hosts file. See Table 16 for the location of the hosts
file for your particular platform.
Edit the client’s hosts file and add an entry for the server’s hostname. For
example:
9.21.15.235 serverhost # host address for serverhost
where:
9.21.15.235 represents the ip_address
serverhost represents the hostname
# represents a comment describing the entry
If the server is not in the same domain as the client, you must provide a fully
qualified domain name such as serverhost.vnet.ibm.com, where
vnet.ibm.com is the domain name.
Using a local text editor, add the Connection Service name and port number
to the client’s services file for TCP/IP support. For example:
server1 3700/tcp # DB2 connection service port
The services file is located in the same directory as the local hosts file that
you may have edited in “A. Resolve the Server’s Host Address” on page 185.
Ensure that you did not specify a port number that is being used by the Fast
Communications Manager (FCM) or any other process.
See Table 16 on page 186 for the location of the services file for your particular
platform.
Step 2. If you are using a UNIX client, run the start-up script as follows:
. INSTHOME/sqllib/db2profile (for bash, Bourne or Korn shell)
source INSTHOME/sqllib/db2cshrc (for C shell)
Chapter 16. Configuring Client-to-Server Communications Using the Command Line Processor 187
Step 3. Catalog the node by entering the following commands:
db2 "catalog tcpip node node_name remote [hostname|ip_address]
server [svcename|port_number]"
db2 terminate
If you need to change values that were set with the catalog node
command, perform the following steps:
Step 1. Run the uncatalog node command in the command line
processor as follows:
db2 uncatalog node node_name
Step 2. Recatalog the node with the values that you want to use.
Step 3. If you are using a UNIX client, run the start-up script as follows:
. INSTHOME/sqllib/db2profile (for bash, Bourne or Korn shell)
source INSTHOME/sqllib/db2cshrc (for C shell)
Chapter 16. Configuring Client-to-Server Communications Using the Command Line Processor 189
db2 catalog database sample as tor1 at node db2node
db2 terminate
If you need to change values that were set with the catalog database
command, perform the following steps:
Step a. Run the uncatalog database command as follows:
db2 uncatalog database database_alias
Step b. Recatalog the database with the value that you want to use.
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 for
a DB2 server and on the host or AS/400 machine for a DB2 Connect server.
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 CLP:
"select tabname from syscat.tables"
When you are finished using the database connection, enter the command
reset command to end the database connection.
You are now ready to start using DB2. For more advanced topics, refer
to the Administration Guide and the Installation and Configuration
Supplement.
At the server:
1. The db2comm registry value includes the value tcpip.
Check the settings for the db2comm registry value by entering the
db2set DB2COMM command. For more information, refer to the
Administration Guide.
At the client:
1. If used, the services and hosts files were updated correctly.
2. The node was cataloged with the correct hostname (hostname) or IP
address (ip_address).
3. The port number matches, or the sevices name maps to, the port number
used on the server.
4. The node name (node_name) that was specified in the database directory
points to the correct entry in the node directory.
5. The database was cataloged properly, using the server’s database alias (the
database_alias that was cataloged when the database was created on the
server), as the database name (database_name) on the client.
Chapter 16. Configuring Client-to-Server Communications Using the Command Line Processor 191
If the connection still fails after you verify these items, refer to the
Troubleshooting Guide.
You can also start the CCA by entering the db2cca command at a command
prompt.
Note: If you do not have the Control Center installed, a Command Center
with limited functionality is available through the IBM DB2 program
group, or by entering the db2cctr command.
To start the Command Center, click on the Command Center icon in the
Control Center.
The Command Center contains a large input area for entering commands. To
run the commands you have entered, click on the Execute icon (the gears
icon).
If you want to enter multiple commands, you must end each command with
the termination character, then press Enter to start the next command on a
new line. The default termination character is a semicolon (;).
For example, you could connect to a database called SAMPLE and list all the
system tables by entering the following command:
connect to sample;
list tables for system
After you have clicked on the Execute icon, the results are displayed.
To recall commands that you have entered during your session, select the
Command history drop down box, and select a command.
To save commands, select Interactive —> Save Command As from the menu
bar. For more information, click on the Help push button or press the F1 key.
You can use the Append to Script button and the Script page of the
Command Center to store commonly used SQL statements or DB2
commands as scripts. For more information, click on the Help push
button or press the F1 key.
If you are entering commands via the Command Window, you must include
the db2 prefix. For example:
db2 list database directory
To enter a long command that does not fit on a single line, you must use a
space followed by the line continuation character ″\″ at the end of one line,
then press the Enter key to continue the command on to the next. For
example:
db2 select empno, function, firstname, lastname, birthdate, from \
db2 (cont.) => employee where function='service' and \
db2 (cont.) => firstname='Lily' order by empno desc
In interactive input mode, you do not have to enter DB2 commands with a
db2 prefix; instead, you just enter the DB2 command. For example:
db2 => list database directory
To enter a long command that does not fit on a single line, you must use a
space followed by the line continuation character ″\″ at the end of one line,
then press the Enter key to continue the command on to the next. For
example:
db2 select empno, function, firstname, lastname, birthdate, from \
db2 (cont.) => employee where function='service' and \
db2 (cont.) => firstname='Lily' order by empno desc
For more information on advanced topics using the CLP, refer to the Command
Reference.
Note that some window managers may automatically mount your CD-ROM
for you. Consult your system documentation for more information.
Mounting the CD-ROM on PTX
To mount the CD-ROM on PTX:
1. Log in as a user with root authority.
2. Insert the CD-ROM in the drive and enter the following commands:
mkdir /cdrom
mount -r -F cdfs /dev/dsk/cd0 /cdrom
Note: If you are mounting the CD-ROM drive from a remote system using
NFS, the CD-ROM file system on the remote machine must be
exported with root access. You must also mount that file system
with root access on the local machine.
If you are using an SMP machine and you have purchased additional
processor entitlements, you can update this information using the db2licm
command.
Code Page and Language Support for OS/2 and Windows Operating
Environments
During installation of DB2, the country, codepage, and regional settings are
established. However, you can change these settings after installing DB2:
including regional settings such as code page, country language (for monetary,
date, and numeric formatting), and time zone. When a new connection to a
database is made, the database manager uses these new values.
You must ensure that your regional settings are set correctly. DB2 may not
produce the expected results if the country, code page, or regional settings are
incorrect for the intended language. Table 18 on page 206 shows the languages
into which the DB2 messages are translated. If the setup is run on a machine
that is set up using a non-supported language, then English is the default
unless the user has specified otherwise.
Unless otherwise specified, all names must begin with one of the following
characters:
v A through Z
v @, #, and $
Do not use SQL reserved words to name tables, views, columns, indexes, or
authorization IDs. For a list of SQL reserved words, refer to SQL Reference.
When naming database objects, see “General Naming Rules” on page 207.
For example, if you create a column with a + or − sign included in the name
and you subsequently use that column in an index, you will experience
For a node that does not own an instance, its NetBIOS nname is derived as
follows:
1. The first character of the instance-owning machine’s workstation nname is
used as the first character of the node’s NetBIOS nname.
2. The next 1 to 3 characters represent the node number. The range is from 1
to 999.
3. The remaining characters are taken from instance-owning machine’s
workstation nname. The number of remaining characters depend on the
length of the instance-owning machine’s workstation nname. This number
can be from 0 to 4.
For example:
Password Rules
When determining passwords, consider the following rules:
OS/2 A maximum of 14 characters.
UNIX A maximum of 8 characters.
Windows 32-bit operating systems
A maximum of 14 characters.
UNIX AS/400
Server Server
Enterprise-
Extended
Edition
DB2 Products
The name DB2 is used for relational database products that run on a variety
of platforms.
DB2 Everywhere
DB2 Everywhere is a very small footprint database that runs on mobile
devices, such as personal digital assistants (PDAs), smart phones, and
DB2 Everywhere Sync Server, running on a mid-tier server, replicates the data
in both directions between mobile devices and the enterprise database. For
example, each worker in a loading dock might carry a PDA that is
periodically synchronized with an inventory database on OS/390.
DB2 Universal Database
The following table shows which products are available on each platform:
Table 19. DB2 Universal Database Platforms
Edition Windows Windows NT/ OS/2 Linux AIX HP-UX Solaris PTX/NUMA-Q
95/98 Windows 2000
Satellite U U
Personal U U U U
Workgroup U U U U U U
Enterprise U U U U U U U
Enterprise - Extended U U U U U
Note: DB2 UDB Workgroup Edition, DB2 UDB Enterprise Edition, and DB2
UDB Enterprise - Extended Edition are commonly referred to as
″servers″ or ″DB2 servers″. Various clients are provided with each
server product.
Satellite Edition
DB2 UDB Satellite Edition is a single-user, small footprint version of DB2
available for Windows 32-bit operating systems. It is designed for occasionally
connected remote systems, such as laptop computers.
Typically, many instances of DB2 UDB Satellite Edition are managed centrally
by the same server.
Personal Edition
DB2 UDB Personal Edition is a single-user version of the full DB2 product. It
contains:
v An object-relational database engine
v Business intelligence support, through the OLAP Starter Kit
v Data warehouse support, through the Data Warehouse Center
v Multimedia support, through DB2 Extenders
v Access to a variety of IBM data sources, through DB2 DataJoiner
v Replication support, through DataPropagator
v Extended GUI administration tools, through DB2 Control Center
Workgroup Edition
DB2 UDB Workgroup Edition is a multi-user version of the DB2 product,
designed for a small business or departmental environment. It contains all the
functionality of the Personal Edition, plus:
v The ability for remote clients to access data and perform administration on
a DB2 workgroup server
v Web access, through Net.Data
v IBM WebSphere Application Server
Enterprise Edition
DB2 UDB Enterprise Edition is designed for large databases with many users.
It contains all the functionality of the Workgroup Edition, plus:
v A license for an unlimited number of client connections
v A license for an unlimited number of web client connections
v DB2 Connect support, with DRDA access to host DB2 systems
Developer Editions
Two special editions of DB2 are available for people who develop DB2
applications:
v DB2 Personal Developer’s Edition
v DB2 Universal Developer’s Edition
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 215
Host Databases
The following DB2 products are available for IBM midrange and mainframe
systems:
v DB2 UDB for AS/400
v DB2 Server for VSE & VM
v DB2 UDB for OS/390
DB2 Connect
DB2 Connect provides connectivity to mainframe and midrange databases
from Windows, OS/2, and UNIX-based platforms. You can connect to DB2
databases on OS/400, VSE, VM, MVS, and OS/390. You can also connect to
non-IBM databases that comply with the Distributed Relational Database
Architecture (DRDA).
DB2 Connect
Personal Edition
DB2 Connect
Enterprise Edition
Related Products
The following products work together with DB2 Universal Database.
DB2 Relational Connect
DB2 Relational Connect gives you the ability to access federated data by
joining DB2 data with Oracle data within a query. It works under DB2 UDB
Enterprise Edition or Enterprise - Extended Edition on Windows NT,
Windows 2000, and AIX.
DB2 Warehouse Manager
DB2 Warehouse Manager provides a warehouse or data mart administrator
with enhanced management capabilities. It provides the ability to manage the
process of moving data as well as manage the ad hoc query workload going
against the warehouse or mart. This product includes:
v Warehouse agents, which manage the flow of data between sources and
warehouse targets.
v Warehouse transformers, which clean and transform data moving into the
warehouse.
v An integrated business information catalog, which guides users to the data
that they want.
v Metadata interchange with end-user repositories and CASE tools.
v A sophisticated query management and workload distribution tool, DB2
Query Patroller, which was previously a separate product. In order to use
Query Patroller, you must have a Query Patroller server installed. Query
Patroller client support is only available with a DB2 Administration Client.
For more information, refer to DB2 Query Patroller Administration Guide.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 217
This product is available for DB2 UDB Enterprise Edition and Enterprise -
Extended Edition systems.
DB2 OLAP Server
DB2 OLAP Server provides fast, intuitive online analytic processing of data to
afford users quick access to information. OLAP servers process
multidimensional requests that calculate, consolidate, and retrieve information
from multidimensional and relational databases.
The OLAP Starter Kit, which supports only three concurrent users, is installed
with DB2 Universal Database. You can later upgrade the OLAP Starter Kit to
the full DB2 OLAP Server product.
Intelligent Miner
The Intelligent Miner family consists of two products:
v DB2 Intelligent Miner for Data extracts valuable information from a large
quantity of data in a relational database.
v Intelligent Miner for Text works with unstructured information, such as text
files, email, and web pages.
DB2 Spatial Extender
DB2 Spatial Extender lets you integrate geographical data with your existing
business data. It includes:
v Data types such as points, lines, and polygons
v Functions such as area, endpoint, and intersect
v An indexing scheme for spatial data
This product is available for DB2 UDB Enterprise Edition and Enterprise -
Extended Edition systems.
DB2 Net Search Extender
DB2 Net Search Extender contains a DB2 stored procedure that adds the
power of fast full-text retrieval to Net.Data, Java, or DB2 CLI applications. It
offers application programmers a variety of search functions, such as fuzzy
Figure 5 on page 220 shows a server that is being accessed by local and remote
applications. Remote applications must have the appropriate DB2 client
installed to enable applications to access data on the remote server.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 219
DB2 Universal Database Enterprise - Extended Editon - Remote Client Support
Application 1
Application n
Application 2
Communication Support
for Server
A great deal of the data in many large organizations is managed by DB2 for
AS/400, DB2 for MVS/ESA, DB2 for OS/390, or DB2 for VSE & VM.
Applications that run on any of the supported platforms can work with this
data transparently, as if a local database server managed it. DB2 Connect
Enterprise Edition is required for supporting applications which access host or
AS/400 data and exploit transaction monitors (for example, IBM TxSeries
CICS and Encina Monitor, Microsoft Transaction Server, BEA Tuxedo) as well
as applications that are implemented as Java applets.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 221
In addition, you can use a wide range of off-the-shelf or custom-developed
database applications with DB2 Connect and its associated tools. For example,
you can use DB2 Connect products with:
v Spreadsheets, such as Lotus 1-2-3 and Microsoft Excel, to analyze real-time
data without having the cost and complexity of data extract and import
procedures.
v Decision support tools, such as BusinessObjects, Brio and Impromptu, and
Crystal Reports, to provide real-time information.
v Database products, such as Lotus Approach and Microsoft Access.
v Development tools, such as PowerSoft PowerBuilder, Microsoft Visual Basic,
and Borland Delphi, to create client/server solutions.
A DB2 server with the DB2 Connect functionality installed, or a DB2 Connect
server, enables multiple clients to connect to host or AS/400 data and can
significantly reduce the effort that is required to establish and maintain access
In the example, you could replace the DB2 Connect server with a DB2 server
that has the DB2 Connect Server Support component installed.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 223
DB2 Connect Enterprise Edition
DB2 for
MVS
DB2 for
VM AS/400
S/390, S/370
OS/390 APPC TCP/IP*** MPTN
Coax* Ethernet Asynch Twinax**
SDLC Token-ring X.25
Communication Support
Application 1
Application 2
The DB2 JDBC Applet server and the DB2 client must reside on the same
machine as the Web server. The DB2 JDBC Applet server calls the DB2 client
to connect to local, remote, host, and AS/400 databases. When the applet
requests a connection to a DB2 database, the JDBC client opens a TCP/IP
connection to the DB2 JDBC Applet on the machine where the Web server is
running. See Figure 8 on page 226 for an example of a Java-enabled browser
accessing data from remote DB2 databases.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 225
Accessing DB2 Data Using JDBC
Java-enabled
Web Browsers World Wide Web
(Internet)
HTTP
Web Server
and
JDBC Applet Server
DB2 Client
JDBC and SQLJ applications can be run from any system that has a DB2 client
installed; a Web browser and a Web server are not required.
For more information on Java enablement, refer to the DB2 Java Enablement
web page at http://www.ibm.com/software/data/db2/java/
Automated queries do not require user input; they are links in an HTML
document and, when selected, they trigger existing SQL queries and return
Web Browser
World Wide Web
(Internet)
Web Server
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 227
Accessing DB2 Data from Host and AS/400 Client Machines
The DRDA Application Server (DRDA AS) functionality gives clients or
applications on host and AS/400 machines transparent access to data stored
on a LAN-based DB2 Universal Database server. This access is provided
through Distributed Relational Database Architecture (DRDA), a standard
architecture for managing data. You can configure your server to act as a
DRDA AS for host and AS/400 clients or applications; these clients or
applications are known as DRDA Application Requesters (DRDA AR).
The listener daemon requires a predefined named port. The named port must
be called db2ccmsrv and must be defined in the /etc/services file on every
machine. The named port can be assigned any unused port number, but the
same number must be used for all machines.
Managing Instances and Database Objects using the Control Center
The Control Center displays instances and database objects (such as table
spaces, tables, and packages) and their relationships to each other. Using the
Control Center, you can manage local and remote servers from a single point
of control. See Figure 10 on page 229 for an example of the main Control
Center window.
From the Control Center, you can perform operations on database objects.
These operations include:
v Create and drop a database
v Create, alter, and drop a table space or table
v Create, alter, and drop an index
v Create nodegroups
v Backup and recover a database partition or table space partition.
v Define the replication sources and subscriptions to replicate data between
systems
v Monitor resources and events on a server.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 229
Wizards are provided to help you perform complex tasks. For example, a
wizard is available to tune the performance of your system. See “Using DB2
Wizards” on page 252 for descriptions of the various wizards and how to start
them.
Control Center
Use the Control Center to start another session of the Control Center
to administer a server.
Satellite Center
Use the Satellite Center to manage the Satellites that are served by a
particular DB2 Control Server. It provides create, remove, modify, and
manage functions for Satellites and Groups. You can also create and
manage scripts to administer the Satellites.
Data Warehouse Center
Use the Data Warehouse Center to manage warehouses; create and
manage warehouse objects, such as sources and targets; define,
extract, transform, manipulate, and load steps and processes; and
schedule and automate steps.
Command Center
Use the Command Center to enter DB2 commands and SQL
statements in an interactive window and see the execution result in a
result window. You can scroll through the results and save the output
to a file.
Script Center
Use the Script Center to create scripts, which you can store and
invoke at a later time. These scripts can contain DB2 commands, SQL
statements, as well as operating system commands. Scripts can be
scheduled to run unattended. These jobs can be run once or set up to
run on a repeating schedule; a repeating schedule is particularly
useful for tasks like backup.
You can also analyze performance using the DB2 Performance Monitor and
Visual Explain. These tools are available from the Control Center.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 231
You can find additional information in the Administration Guide or in the
online help.
Managing Communications on the Server
The Control Center allows you to maintain or edit server protocol settings in
the database manager configuration file.
v Configure database manager parameters by clicking with the right mouse
button on an instance and selecting the Configure option from the pop-up
menu. By default, the setup program automatically detects and configures
most communication protocols that it detects on your system.
v Export database information in a profile that can be used to configure
clients by clicking with the right mouse button on a system and selecting
the Export Server Profile option from the pop-up menu.
You can choose to monitor the current state of database activity or collect
information when specific events occur. The Performance Monitor allows you
to capture point-in-time information at specified intervals. The Event Analyzer
allows you to view information about the occurrence of events such as
deadlocks and transaction completions.
For additional information, refer to the Administration Guide or the online help.
You are also able to use the Windows Performance Monitor (supported on
Windows NT and Windows 2000) to monitor both database and system
performance. For information on how to register DB2 resources and to use the
Windows Performance Monitor, refer to the Administration Guide.
Viewing SQL Access Plans using Visual Explain
Visual Explain helps database administrators and application developers to:
v View the access plan chosen by the database manager’s optimizer for a
given SQL statement.
v Tune SQL statements for better performance.
v Design application programs and databases.
For additional information, refer to the Administration Guide or the online help.
The Client Configuration Assistant (CCA) helps you manage your database
connections to remote servers. The CCA is available on OS/2 and Windows
32-bit operating systems and this is the preferred method to set up any OS/2,
Windows 9x, Windows NT, or Windows 2000 client to communicate with a
server.
You can use the command line processor to set up DB2 clients on any
platform. For more information, see “Chapter 16. Configuring Client-to-Server
Communications Using the Command Line Processor” on page 183.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 233
v Export client configuration information to a profile.
v Import configuration information from a profile.
v Update the server password.
From the Data Warehouse Center, you can manage specific warehousing
objects, including subject areas, warehouse sources, warehouse targets, agents,
agent sites, steps, and processes.
You can also perform the following tasks from the Data Warehouse Center:
v Define a subject area. You use a subject area to logically group the processes
that are related to a particular topic or function.
v Explore the source data and define warehouse sources.
v Create database tables and define warehouse targets.
v Define a process that specifies how to move and transform the source data
into the appropriate format for the warehouse.
v Test and schedule steps.
v Define security and monitor database currency.
v Define a star schema model.
The Administration Server (DAS) must reside on every server that you want
to administer and detect. By default the DAS is DB2AS, which is the default
user ID that is created using the db2setup utility.
Through a DB2 client, these applications can access all servers and, by using
the DB2 Connect product (or the DB2 Connect functionality supplied with
DB2 Enterprise - Extended or DB2 Enterprise Edition), they can also access
DB2 Universal Database for AS/400, DB2 Universal Database for OS/390, and
DB2 for VSE & VM database servers.
Appendix D. About DB2 Universal Database for UNIX, Windows, and OS/2 235
v An SQL92 and MVS Conformance Flagger to identify embedded SQL
statements in applications not conforming to the ISO/ANSO SQL92 Entry
Level standard, or which are not supported by DB2 for OS/390.
For complete information on the functionality of the DB2 Application
Development Client, and instructions on how to use them, as well as a full list
of supported compilers for your platform, refer to the Application Building
Guide.
To access product information online, you can use the Information Center. For
more information, see “Accessing Information with the Information Center”
on page 251. You can view task information, DB2 books, troubleshooting
information, sample programs, and DB2 information on the Web.
The installation manuals, release notes, and tutorials are viewable in HTML
directly from the product CD-ROM. Most books are available in HTML on the
product CD-ROM for viewing and in Adobe Acrobat (PDF) format on the DB2
publications CD-ROM for viewing and printing. You can also order a printed
copy from IBM; see “Ordering the Printed Books” on page 247. The following
table lists books that can be ordered.
On OS/2 and Windows platforms, you can install the HTML files under the
sqllib\doc\html directory. DB2 information is translated into different
On UNIX platforms, you can install multiple language versions of the HTML
files under the doc/%L/html directories, where %L represents the locale. For
more information, refer to the appropriate Quick Beginnings book.
You can obtain DB2 books and access information in a variety of ways:
v “Viewing Information Online” on page 250
v “Searching Information Online” on page 254
v “Ordering the Printed Books” on page 247
v “Printing the PDF Books” on page 246
Table 20. DB2 Information
Name Description Form Number HTML
Directory
PDF File Name
DB2 Guide and Reference Information
Administration Guide Administration Guide: Planning provides SC09-2946 db2d0
an overview of database concepts, db2d1x70
information about design issues (such as
logical and physical database design),
and a discussion of high availability.
Notes:
1. The character x in the sixth position of the file name indicates the
language version of a book. For example, the file name db2d0e70 identifies
the English version of the Administration Guide and the file name db2d0f70
identifies the French version of the same book. The following letters are
used in the sixth position of the file name to indicate the language version:
Language Identifier
Brazilian Portuguese b
2. Late breaking information that could not be included in the DB2 books is
available in the Release Notes in HTML format and as an ASCII file. The
HTML version is available from the Information Center and on the
product CD-ROMs. To view the ASCII file:
v On UNIX-based platforms, see the Release.Notes file. This file is located
in the DB2DIR/Readme/%L directory, where %L represents the locale name
and DB2DIR represents:
– /usr/lpp/db2_07_01 on AIX
– /opt/IBMdb2/V7.1 on HP-UX, PTX, Solaris, and Silicon Graphics IRIX
– /usr/IBMdb2/V7.1 on Linux.
v On other platforms, see the RELEASE.TXT file. This file is located in the
directory where the product is installed. On OS/2 platforms, you can
also double-click the IBM DB2 folder and then double-click the Release
Notes icon.
Printing the PDF Books
If you prefer to have printed copies of the books, you can print the PDF files
found on the DB2 publications CD-ROM. Using the Adobe Acrobat Reader,
you can print either the entire book or a specific range of pages. For the file
name of each book in the library, see Table 20 on page 238.
The PDF files are included on the DB2 publications CD-ROM with a file
extension of PDF. To access the PDF files:
1. Insert the DB2 publications CD-ROM. On UNIX-based platforms, mount
the DB2 publications CD-ROM. Refer to your Quick Beginnings book for
the mounting procedures.
2. Start the Acrobat Reader.
3. Open the desired PDF file from one of the following locations:
v On OS/2 and Windows platforms:
x:\doc\language directory, where x represents the CD-ROM drive and
language represent the two-character country code that represents your
language (for example, EN for English).
v On UNIX-based platforms:
/cdrom/doc/%L directory on the CD-ROM, where /cdrom represents the
mount point of the CD-ROM and %L represents the name of the desired
locale.
You can also copy the PDF files from the CD-ROM to a local or network drive
and read them from there.
Ordering the Printed Books
You can order the printed DB2 books either individually or as a set (in North
America only) by using a sold bill of forms (SBOF) number. To order books,
contact your IBM authorized dealer or marketing representative, or phone
1-800-879-2755 in the United States or 1-800-IBM-4YOU in Canada. You can
also order the books from the Publications Web page at
http://www.elink.ibmlink.ibm.com/pbl/pbl.
Two sets of books are available. SBOF-8935 provides reference and usage
information for the DB2 Warehouse Manager. SBOF-8931 provides reference
and usage information for all other DB2 Universal Database products and
features. The contents of each SBOF are listed in the following table:
Information Catalog
Manager Help
Satellite Administration
Center Help
You can view the online books or sample programs with any browser that
conforms to HTML Version 3.2 specifications.
You can also access the Information Center by using the toolbar and the Help
menu on the DB2 Windows platform.
The Information Center provides a find feature, so you can look for a specific
topic without browsing the lists.
For a full text search, follow the hypertext link in the Information Center to
the Search DB2 Online Information search form.
Refer to the release notes if you experience any other problems when
searching the HTML information.
Note: The Search function is not available in the Linux, PTX, and Silicon
Graphics IRIX environments.
Using DB2 Wizards
Wizards help you complete specific administration tasks by taking you
through each task one step at a time. Wizards are available through the
Control Center and the Client Configuration Assistant. The following table
lists the wizards and describes their purpose.
Note: The Create Database, Create Index, Configure Multisite Update, and
Performance Configuration wizards are available for the partitioned
database environment.
For information about how you can serve the DB2 Universal Database online
documentation files from a central machine, refer to the NetQuestion
Appendix in the Installation and Configuration Supplement.
Searching Information Online
To find information in the HTML files, use one of the following methods:
v Click Search in the top frame. Use the search form to find a specific topic.
This function is not available in the Linux, PTX, or Silicon Graphics IRIX
environments.
v Click Index in the top frame. Use the index to find a specific topic in the
book.
v Display the table of contents or index of the help or the HTML book, and
then use the find function of the Web browser to find a specific topic in the
book.
v Use the bookmark function of the Web browser to quickly return to a
specific topic.
v Use the search function of the Information Center to find specific topics. See
“Accessing Information with the Information Center” on page 251 for
details.
3. Log out.
4. Stop the instance.
To stop a database instance:
a. Log in as the instance owner.
b. Run the start up script:
. INSTHOME/ sqllib/db2profile (bash, Bourne, or Korn shells)
source INSTHOME/sqllib/db2cshrc (C shell)
where INSTHOME is the home directory of the user who owns the
Administration Server.
3. Back up the files in the ASHOME/sqllib directory, if needed, where ASHOME
is the home directory of the user who owns the Administration Server.
4. Log off.
5. Log in as root and remove the Administration Server by entering the
following command:
DB2DIR/instance/dasidrop ASName
where
The dasidrop command removes the /sqllib directory under the home
directory of the Administration Server.
To remove an instance:
1. Log in as a user with root authority.
2. Remove the instance by entering the following command:
DB2DIR/instance/db2idrop InstName
where
The db2idrop command removes the instance entry from the list of
instances and removes the INSTHOME/sqllib directory, where INSTHOME
is the home directory of the instance and where InstName is the login
name of the instance.
3. Optionally, as a user with root authority, remove the instance owner’s user
ID and group (if used only for that instance). Do not remove these if you
are planning to re-create the instance.
This step is optional since the instance owner and the instance owner
group may be used for other purposes.
IBM may have patents or pending patent applications covering subject matter
described in this document. The furnishing of this document does not give
you any license to these patents. You can send license inquiries, in writing, to:
IBM Director of Licensing
IBM Corporation
North Castle Drive
Armonk, NY 10504-1785
U.S.A.
The following paragraph does not apply to the United Kingdom or any
other country where such provisions are inconsistent with local law:
INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS
PUBLICATION “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER
EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY
OR FITNESS FOR A PARTICULAR PURPOSE. Some states do not allow
disclaimer of express or implied warranties in certain transactions, therefore,
this statement may not apply to you.
Any references in this information to non-IBM Web sites are provided for
convenience only and do not in any manner serve as an endorsement of those
Web sites. The materials at those Web sites are not part of the materials for
this IBM product and use of those Web sites is at your own risk.
IBM may use or distribute any of the information you supply in any way it
believes appropriate without incurring any obligation to you.
Licensees of this program who wish to have information about it for the
purpose of enabling: (i) the exchange of information between independently
created programs and other programs (including this one) and (ii) the mutual
use of the information which has been exchanged, should contact:
IBM Canada Limited
Office of the Lab Director
1150 Eglinton Ave. East
North York, Ontario
M3C 1H7
CANADA
The licensed program described in this information and all licensed material
available for it are provided by IBM under terms of the IBM Customer
Agreement, IBM International Program License Agreement, or any equivalent
agreement between us.
This information may contain examples of data and reports used in daily
business operations. To illustrate them as completely as possible, the examples
include the names of individuals, companies, brands, and products. All of
these names are fictitious and any similarity to the names and addresses used
by an actual business enterprise is entirely coincidental.
COPYRIGHT LICENSE:
Each copy or any portion of these sample programs or any derivative work
must include a copyright notice as follows:
© (your company name) (year). Portions of this code are derived from IBM
Corp. Sample Programs. © Copyright IBM Corp. _enter the year or years_. All
rights reserved.
ACF/VTAM IBM
AISPO IMS
AIX IMS/ESA
AIX/6000 LAN DistanceMVS
AIXwindows MVS/ESA
AnyNet MVS/XA
APPN Net.Data
AS/400 OS/2
BookManager OS/390
CICS OS/400
C Set++ PowerPC
C/370 QBIC
DATABASE 2 QMF
DataHub RACF
DataJoiner RISC System/6000
DataPropagator RS/6000
DataRefresher S/370
DB2 SP
DB2 Connect SQL/DS
DB2 Extenders SQL/400
DB2 OLAP Server System/370
DB2 Universal Database System/390
Distributed Relational SystemView
Database Architecture VisualAge
DRDA VM/ESA
eNetwork VSE/ESA
Extended Services VTAM
FFST WebExplorer
First Failure Support Technology WIN-OS/2
Java or all Java-based trademarks and logos, and Solaris are trademarks of
Sun Microsystems, Inc. in the United States, other countries, or both.
Tivoli and NetView are trademarks of Tivoli Systems Inc. in the United States,
other countries, or both.
Index 267
passwords server profiles (continued) TCP/IP (continued)
naming rules 211 definition 178 software requirements 22, 23, 24
PDF 246 setting configuration troubleshooting 184
performance configuration parameters 183 verifying on OS/2 164
wizard 253 setting up client communications Tivoli Enterprise
Performance Monitor using the Command Line overview 219
using 232 Processor 183 Tools Setting 231
Personal Edition setting up document server 253 transparent parallelism 4
overview 214 shared-nothing configuration
planning definition 3 U
DB2 configuration 17 storage 7 username
DB2 Connect configuration 17 SmartGuides naming rules 209
pools wizards 252
agent 10 software requirements V
printing PDF books 246 communication protocols 19 verifying the connection
privileges DB2 Application Development TCP/IP 183
required 199 Clients 19, 21, 22, 23, 24, 25 viewing
product DB2 clients 19, 21, 22, 23, 24, 25 online information 250
descriptions 213 DB2 Connect 19 Visual Explain
overview 213 DB2 Universal Database 19 overview 232
profiles Net.Data 21, 22, 23, 24, 25
client 178, 179 Solaris W
export 178 mounting CD-ROM 202 Warehouse Manager
server 178 Solaris client overview 217
protocols updating kernel well-known address
TCP/IP 183 components 152 description 12
PTX Spatial Extender Windows 2000
mounting CD-ROM 201 overview 218 starting the security server 159
Windows NT
SQL
Q viewing using Visual
starting the security server 159
query wizards
Explain 232
cost-based optimizer 4 add database 252, 253
Stored Procedure Builder 231
backup database 252
symmetric multiprocessor
R architecture 10
completing tasks 252
Relational Connect configure multisite update 252
SYSADM create database 253
overview 217
controlling 199 create table 253
release notes 246
restore wizard 253 SYSADM_GROUP parameter 199 create table space 253
restrictions system configuration index 253
instance name 209 with DB2 Connect 223 performance configuration 253
with DB2 Universal restore database 253
S Database 220 Workgroup Edition
sample programs overview 215
cross-platform 245 T working with DB2 data 219
HTML 245 tables workstation name (nname)
Satellite Edition maximum size 7 naming rules 209
overview 214 multinode nodegroups 10
scaling the database system single-node nodegroups 10
definition 10 TCP/IP
Script Center 230 client 183
searching configuring 183
online information 252, 254 configuring on OS/2 163
security enabling localhost on OS/2 163
for an instance 11 enabling loopback on OS/2 163
server profiles preventing socket collisions 184
creating 179 setting up client-to-server 183
If you live in the U.S.A., then you can call one of the following numbers:
v 1-800-237-5511 for customer support
v 1-888-426-4343 to learn about available service options
Product Information
If you live in the U.S.A., then you can call one of the following numbers:
v 1-800-IBM-CALL (1-800-426-2255) or 1-800-3IBM-OS2 (1-800-342-6672) to
order products or get general information.
v 1-800-879-2755 to order publications.
http://www.ibm.com/software/data/
The DB2 World Wide Web pages provide current DB2 information
about news, product descriptions, education schedules, and more.
http://www.ibm.com/software/data/db2/library/
The DB2 Product and Service Technical Library provides access to
frequently asked questions, fixes, books, and up-to-date DB2 technical
information.
For information on how to contact IBM outside of the United States, refer to
Appendix A of the IBM Software Support Handbook. To access this document,
go to the following Web page: http://www.ibm.com/support/, and then
select the IBM Software Support Handbook link near the bottom of the page.
GC09-2964-01