3.3. Installing DB2 Using the DB2 Setup WizardThe DB2 Setup Wizard uses a step-by step-method to guide you through the installation process, perform the tasks listed in Figure 3.1, and keep an installation log. Refer to the documentation that comes with DB2 for the complete installation instructions. The following steps highlight the main points. Note that there are different first steps for Windows and Linux/UNIX, but that the procedure is mostly the same. For simplicity, we have used screen shots from the Windows installation in this section. 3.3.1. Step 1 for Windows: Launch the DB2 Setup WizardTo start the installation of DB2 on Windows, you must log on to the system with a user ID that belongs to the local Administrators group and has the Act as part of the operating system advanced user right.
From the launchpad, you have the option to view the installation prerequisites and the release notes, or to proceed directly to the installation. Select Install Products and then select the DB2 product to install. The DB2 Setup Wizard will determine your system's language and launch the setup program in that language. If you want to run the setup program in a different language, or if the setup program fails to start automatically, you can start the DB2 Setup Wizard manually and use the /i option to specify a language. To start the DB2 Setup Wizard manually, change to the CD-ROM drive and double-click on setup. Alternatively, click on Start > Run. In the Open field, enter the following command: x:\setup /i language where:
If the /i flag is not specified, the installation program will run in the default language of the operating system. You can also click Browse, change to the CD-ROM drive, and run Setup. Continue with step 2. 3.3.2. Step 1 for Linux/UNIX: Launch the DB2 Setup WizardThe DB2 Setup Wizard is also available on Linux/UNIX platforms. You must have X-Windows software capable of rendering a graphical user interface for the DB2 Setup Wizard to run this on your machine. Do one of the following:
For example, if the product name for DB2 Enterprise Server Edition is ese, enter the following command: zcat ese.tar.Z | tar -xf - ; ./ese/db2setup You will see the same DB2 Setup Launchpad as shown in Figure 3.3. Continue with step 2. 3.3.3. Step 2: Choose an Installation TypeAs shown in Figure 3.4, you can select one of three installation types.
Figure 3.4. Selecting the installation type3.3.4. Step 3: Choose Whether to Generate a Response FileAs mentioned earlier, a response file allows you to perform DB2 installation on other computers in an unattended mode (refer to section 3.4, Silent Install Using a Response File, for information on how to do this). If you need to install DB2 with the same configuration on other computers, it is a good idea to create a response file by selecting the Save your settings in a response file option (see Figure 3.5). Figure 3.5. Selecting the installation action3.3.5. Step 4: Indicate Whether This Machine Will Be Part of a Partitioned Database EnvironmentIf this machine will be part of a partitioned database environment, select the Partitioned database environment option, then indicate whether this is going to be the instance owning machine, that is, where the DB2 instance will be created (see Figure 3.6). Figure 3.6. Selecting how this computer will be used3.3.6. Step 5: Specify the Installation FolderBy default, DB2 will be installed in C:\Program Files\IBM\SQLLIB (see Figure 3.7). You can specify another drive and directory if you wish.
Figure 3.7. Selecting the installation folder3.3.7. Step 6: Set User Information for the DB2 Administration ServerThe DAS is a special service needed to support the DB2 graphical administration tools and assist with administrative tasks on local and remote DB2 servers. Each server can have only one DAS. During the installation the DAS is configured to start when the operating system is started. You can specify either a local user or a domain user. If specifying a domain user, click on the domain drop down list and choose the domain. Otherwise, leave it blank. If the user does not already exist, it will be created and granted the appropriate rights. If the user already exists, DB2 will grant it the appropriate rights. If you are creating a domain user, the user ID you are using for this installation must belong to the administrator group of the domain. Click on Next to proceed. Figure 3.8. Setting DAS user information3.3.8. Step 7: Enable the Alert Notification FeatureYou can configure the DAS to send e-mail or pager notifications to administrators should certain conditions occur, such as a disk becoming full. The contact list can be stored on either the local machine or a remote machine (see Figure 3.9).
Figure 3.9. Setting up the administration contact listTo send the notification, select the Enable notification option and specify the hostname of the mail (SMTP) server. If you don't want to specify the SMTP server at this time, you can do this after the installation. (Refer to UPDATE ADMIN CONFIG command in the DB2 UDB Command Reference manual.) 3.3.9. Step 8: Create and Configure the DB2 InstanceBy default, a DB2 instance named DB2 will be created. The DB2 Setup Wizard automatically detects the communication protocols configured on the server and generates communication parameter values for the instance to use, for each detected protocol (see Figure 3.10). Figure 3.10. Configuring the DB2 instance and its communication protocolsClick the Protocols button to display the settings for each protocol. Figure 3.10 shows a list of the supported protocols on Windows: TCP/IP, NetBIOS, and Named Pipes. If a protocol is installed and configured correctly, the Configure option will be checked. Otherwise, the Do not configure at this time option will be checked. You can use the default values or enter different values. The server needs a port number to accept connections from remote DB2 clients using TCP/IP. The clients will connect to the server through this port. If configured, the x:\WINNT\System32\ drivers\etc\services file will be updated, where x represents the Windows install directory. The service name is the name that is associated with the port number in the services file. If you want to specify a different port number, make sure that this number does not already exist in the services file, because you cannot use the same port for two different applications. Figure 3.11 shows that NetBIOS has been detected as well, and shows the workstation name of the DB2 server on the network. The server's NetBIOS name must be unique on the network. Figure 3.11. Configuring NetBIOS communication protocolThe Adapter number is the logical LAN adapter number that is used for the NetBIOS connection. If you do not wish to configure a protocol at this time, choose Do not configure at this time. Figure 3.12 shows that the Name Pipes protocol is not going to be configured. Figure 3.12. Configuring the Named Pipes communication protocolYou can choose to start the DB2 instance automatically during system startup. If you prefer to start it manually (using the db2startcommand) select the Do not autostart the instance option (see Figure 3.13). Figure 3.13. Configuring startup options for the DB2 instance3.3.10. Step 9: Create the DB2 Tools CatalogThe DB2 tools catalog consists of several tables that store information for use by the Task Center and the Journal. We will talk about these tools in Chapter 4, Using the DB2 Tools. If you plan to use these tools, it is a good idea to create the tools catalog now; if not, you can create the tools catalog later using the CREATE TOOLS CATALOG command (see Figure 3.14). Figure 3.14. Preparing the DB2 tools catalogIf you choose to create the tools catalog now, you need to create a database in which to store the catalog information (see Figure 3.15). The default database name is TOOLSDB, with a default schema SYSTOOLS. You can specify different names if you wish. Figure 3.15. Specifying a local database to store the DB2 tools catalog3.3.11. Step 10: Specify a Contact for Health Monitor NotificationThe health monitor automatically tracks database performance. When a health indicator notices an alarm or warning level, it sends an alert to the contact specified in Figure 3.16. Figure 3.16. Specifying a contact for the health monitor notification
The DB2 Setup Wizard in Version 8.2 has a new security feature, which, if enabled, creates two user groups in the operating system security system (see Figure 3.17). Their default names are DB2ADMNS and DB2USERS. Figure 3.17. Enabling operating system security for DB2 objectsAfter successfully completing a DB2 installation, you can add users to the DB2ADMNS or the DB2USERS groups to give them access to DB2. Users in the DB2ADMNS groups have complete control over all DB2 objects in the instance; users in the DB2USERS group have read and execute authorities only. If you choose not to enable the new security feature now, you can still do so after the installation completes by running the db2secv82.exe command. Once you enable this security feature using the db2secv82.exe command, you have two options for backing out. Note that if there have been any changes made to the system you must use the second option.
3.3.13. Step 12: Start the InstallationJust before starting the installation, the DB2 Setup Wizard displays a window summarizing the components that are going to be installed (see Figure 3.18). If you specified in step 3 to save your setting in a response file, the file information displays. Specify the location and name for the response file. Review this window carefully. Click on Back to make any changes; click Finish to start the installation. Figure 3.18. Component summary and response file locationFigure 3.19 shows the window that displays when the DB2 installation is complete. Read the list of recommended steps and click Finish to exit the DB2 Setup Wizard. Figure 3.19. Setup completeWhen you exit the DB2 Setup Wizard, after a successful DB2 installation, the First Steps dialog is automatically launched (see Figure 3.20). From this menu, you have the option to create a sample database, create your own database, check for DB2 updates, or exit First Steps. Figure 3.20. The First Steps dialog |