IBM®
    DB2® Express-C 9.5
    Virtual Appliance

    Installation Guide
I




     Data Management Emerging Partnership ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         Contents

         1.      BEFORE YOU BEGIN.............
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         7.      ADDITIONAL INFORMATION ..........................
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         1.                Before You Begin
         Experienc...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         3.                Hardware and Software Prerequisites...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         4.                Installation of the Virtual Applian...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               4. Open the VMware image that was extracted to a...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         4.1.2             Taking Snapshots of the Virtual Mac...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         4.1.3             (Optional) Networking Configuration ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         The following prompt may pop up. Select “No” to disab...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         4.2.1             Logging on to the DB2 Express-C Virt...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               4. After accepting the license agreements, VMwa...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    size of your host machine.




            ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    Note: Please be sure to remember the root p...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               2. Once system configuration is completed, the ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         4.2.3             DB2 Configuration
         After yo...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                         # yast2 db2config




                ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                4. The db2config module will stop DB2, and rem...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      enter only the password information or ch...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                9. Since this is a reconfiguration of the DB2 ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      created.




                11. The last...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               1. You will be prompted to input the passwords f...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               3. Once the configuration is completed, press [...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         4.2.4             Database creation screen
          ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               3. When the database is successfully created, P...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         4.2.5             WASCE Configuration
         After ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         In addition, this sample can be used to exercise the s...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                9. Another warning screen will ask you to conf...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                10. The db2config module will stop DB2, and re...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      enter only the password information or ch...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                12. Since this is a reconfiguration of the DB2...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      created.




                14. The last...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               1. When the WASCE module is started, it will pro...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               3. Once you have pressed [Next] to continue, th...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               4. Once the DayTrader sample is deployed success...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         The deployment of the DB2 Express-C 9.5 Virtual Applia...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         5.                Working with Your Installed System
...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               7. WASCE V2.0 Documentation
                  A ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         Every time rcdb2 start is executed, it will verify and...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



              # /sbin/sysctl -w <kernel_parameter_name>=<new_va...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         5.1.3.4           Database Configuration Parameters
 ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                           db2set <REGISTRY_PARAMETER>=<VALUE>
...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      db2server:~ # su – db2inst1


           ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         createDatabase script (Section 5.1.4.1 createDatabase ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               5. The tablespaces will then be created. The cre...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         5.2               DB2 Monitoring Console
         Ano...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               4. When the DB2 Monitoring Console is connected...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         5.3               DB2 Control Center
         To laun...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         For your information, the DB2 control center binary f...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    # rcwasce status
                    Checki...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    left panel.




               6. Navigate ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



         In addition, use this sample to exercise the server wh...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                15. Another warning screen will ask you to con...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                16. The db2config module will stop DB2, and re...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      enter only the password information or ch...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




                15. Since this is a reconfiguration of the DB2...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                      created.




                17. The last...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               4. You will be prompted to input the passwords f...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               6. Once the configuration is completed, press [...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         5.5.1             Database creation screen
          ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               7. The next screen will show the progress of th...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               8. When the database is successfully created, P...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         WASCE Configuration)
         To start exploring the ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         There are lots of other WAS CE samples also available...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         6.                Re-configuring Your System
        ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               3. Another warning screen will ask you to confi...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               5. At this point, the system configurations tha...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               6. The final screen will present you with a sum...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         6.2               Re-configuring DB2 Settings

      ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               21. Another warning screen will ask you to conf...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               22. The db2config module will stop DB2, and rem...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    enter only the password information or chan...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               18. Since this is a reconfiguration of the DB2 ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



                    created.




               20. The last sc...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         6.3               Re-configuring WASCE Settings

    ...
IBM® DB2 Express-C Virtual
Appliance Installation Guide



               3. Another warning screen will ask you to confir...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               6. If you have chosen Yes in previous screen, y...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




               8. The following screen will appear when the Da...
IBM® DB2 Express-C Virtual
Appliance Installation Guide




         7.                Additional Information
         Not...
© Copyright IBM Corporation 2008
All Rights Reserved.

IBM Canada
8200 Warden Avenue
Markham, ON
L6G 1C7
Canada

Printed i...
Upcoming SlideShare
Loading in …5
×

DB2 9.5 Bootcamp for Business Partners

488 views
437 views

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
488
On SlideShare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
7
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

DB2 9.5 Bootcamp for Business Partners

  1. 1. IBM® DB2® Express-C 9.5 Virtual Appliance Installation Guide I Data Management Emerging Partnership and Technologies IBM Toronto Lab
  2. 2. IBM® DB2 Express-C Virtual Appliance Installation Guide Contents 1. BEFORE YOU BEGIN.............................................................................. - 4 - 2. INTRODUCTION ...................................................................................... - 4 - 2.1 SOFTWARE COMPONENT TABLE .............................................................- 4 - 3. HARDWARE AND SOFTWARE PREREQUISITES ................................ - 5 - 3.1 HARDWARE AND FIRMWARE PREREQUISITES ...........................................- 5 - 3.2 SOFTWARE PREREQUISITES ...................................................................- 5 - 4. INSTALLATION OF THE VIRTUAL APPLIANCE ................................... - 6 - 4.1 BEFORE YOU START ..............................................................................- 7 - 4.1.1 START HERE SNAPSHOT ON A VIRTUAL MACHINE ..........................- 7 - 4.1.2 TAKING SNAPSHOTS OF THE VIRTUAL MACHINE ................................- 8 - 4.1.3 (OPTIONAL) NETWORKING CONFIGURATION ON A VIRTUAL MACHINE ..- 9 - 4.1.4 STARTING UP THE VIRTUAL MACHINE ...............................................- 9 - 4.2 DEPLOYMENT OF THE DB2 EXPRESS-C VIRTUAL MACHINE ....................- 10 - 4.2.1 LOGGING ON TO THE DB2 EXPRESS-C VIRTUAL MACHINE ...............- 11 - 4.2.2 SYSTEM AND NETWORK CONFIGURATION.......................................- 13 - 4.2.3 DB2 CONFIGURATION ..................................................................- 16 - 4.2.4 DATABASE CREATION SCREEN .......................................................- 24 - 4.2.5 WASCE CONFIGURATION ............................................................- 26 - 5. WORKING WITH YOUR INSTALLED SYSTEM.................................... - 37 - 5.1 STARTING AND STOPPING DB2 SERVICE ...............................................- 38 - 5.1.1 STARTING AND STOPPING DB2 WITH RCDB2 ..................................- 38 - 5.1.2 KERNEL PARAMETER SETTINGS IN RCDB2 ......................................- 39 - 5.1.3 DB2 REGISTRY AND DBM/DB CONFIGURATION SETTINGS ..............- 40 - 5.1.4 DATABASE AND TABLESPACE CREATION UTILITIES ..........................- 42 - 5.1.5 STARTING AND STOPPING WASCE SERVICE USING RCWASCE .........- 45 - 5.2 DB2 MONITORING CONSOLE................................................................- 46 - 5.3 DB2 CONTROL CENTER ......................................................................- 48 - 5.4 WEBSPHERE APPLICATION SERVER COMMUNITY EDITION ADMINISTRATION CONSOLE ......................................................................................................- 49 - 5.5 DAYTRADER SAMPLE APPLICATION ........................................................- 51 - 5.6 INSTALLED SOFTWARE LOCATION .........................................................- 64 - 6. RE-CONFIGURING YOUR SYSTEM ..................................................... - 65 - 6.1 RE-CONFIGURING SYSTEM AND NETWORK SETTINGS .............................- 65 - 6.2 RE-CONFIGURING DB2 SETTINGS.........................................................- 69 - 6.3 RE-CONFIGURING WASCE SETTINGS ..................................................- 75 - -2-
  3. 3. IBM® DB2 Express-C Virtual Appliance Installation Guide 7. ADDITIONAL INFORMATION ............................................................... - 79 - 7.1 FEEDBACK ..........................................................................................- 79 - -3-
  4. 4. IBM® DB2 Express-C Virtual Appliance Installation Guide 1. Before You Begin Experience the power of DB2 by using the provided VMware® DB2 Express-C 9.5 Virtual Appliance image. This image is designed to run in VMware Workstation 5.5 / VMware Player 2.0 or later. Before you begin using the provided DB2 Express-C 9.5 Virtual Appliance, please make sure you read this guide thoroughly in order to ensure the successful deployment of the DB2 Express-C 9.5 Virtual Appliance. 2. Introduction This document details the deployment instructions for DB2 Express-C 9.5 Virtual Machine. This Virtual Machine will allow you to experience the fully functional DB2 data server on a Virtual Appliance. The VM also includes customized YaST modules to guide you through the Virtual Machine configuration steps. Please be sure to follow the instructions below for installation instructions. 2.1 Software Component Table The following matrix is meant to provide you with an overview of the software components, driver versions that are being applied as part of the deployment with the virtual appliance. Component Version Comment SUSE® Linux Enterprise Server 10 + SP2 DB2 Express-C 9.5.0 (DB2 Express-C FTL version includes FixPack 1) WebSphere Application Server 2.0.0.2 Community Edition DB2 Monitoring Console 2.2.25 Light weight, web based console for DB2 for Linux, UNIX® and Windows. ibm_db2 driver 1.6.5 PHP extension for IBM DB2 Universal Database, IBM Cloudscape, and Apache Derby. -4-
  5. 5. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. Hardware and Software Prerequisites Before installation of the DB2 Express-C 9.5 Virtual Appliance can commence, please ensure that you have met all the prerequisites detailed below. 3.1 Hardware and Firmware Prerequisites The DB2 Express-C 9.5 Virtual Appliances are available in both 32-bit and 64-bit versions. For users who have downloaded the 64-bit, it is installed with a 64-bit SUSE® Linux Enterprise Server. Please review the below link for Hardware and Firmware requirements to run a 64-bit guest Operating System Virtual Machine. http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayK C&externalId=1901 In addition to the Hardware and Firmware requirements to run a 64-bit guest Operating System Virtual Machine, the DB2 Express-C 9.5 Virtual Appliances also require the following specification on your host machine: Requirement Specification Memory on host machine Minimum: 1.5 GB Disk space on host machine Minimum: 8.0 GB 3.2 Software Prerequisites This Image is designed to run in VMware Workstation 5.5 / VMware Player 2.0 or later. You may download the software from the VMware website: http://www.vmware.com. -5-
  6. 6. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. Installation of the Virtual Appliance To run the DB2 Express-C Virtual Appliance, perform the following steps: 1. Copy and extract the self-extracting package into a temporary directory. The self-extracting package name should be in the form of: ► DB2-<edition>-<version#>-{ws,ovf}-{32,64}bit.exe where: <edition> stands for the DB2 edition on the Virtual Appliance EXPC – DB2 Express-C Edition EXCFTL – DB2 Express-C Edition (for use with Fixed-Term License) {32,64} indicates whether the Virtual Appliance is a 32-bit or 64-bit Virtual Appliance; <version#> indicates the version number of DB2 installed on the Virtual Appliance. {ws,ovf} indicates whether the Virtual Appliance is in a VMware workstation format (ws) or in VMware OVF Virtual Appliance format (ovf). The VMware OVF Virtual Appliance format can be run on a VMware ESX server. 2. Extract the contents of the package to the desired directory. On Linux® you may use the command: # unrar x DB2-<edition>-<version#>-{ws,ovf}-{32,64}bit.exe (You will need an unrar utility that is supported on your platform.) On Windows®, you can extract the contents by executing the following self- extracting package: DB2-<edition>-<version#>-{ws,ovf}-{32,64}bit.exe Note: The uncompressed Virtual Machine files will take up 4.45 GB of space and the size will grow as you use the Virtual Appliance. Please make sure you have enough free disk space before un-compressing the self-extracted package. 3. Open VMware in your host operating system. -6-
  7. 7. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. Open the VMware image that was extracted to a directory in step one. You may do this by clicking File > Open and browsing to the directory the files were extracted in. 4.1 Before you start 4.1.1 START HERE Snapshot on a Virtual Machine For your convenience, a snapshot of the initial state of the virtual machine is pre-taken for you. At any point in time, if you wish to go back to the very beginning state of the Virtual Machine (before any configuration was started), you can do so by clicking on the (Manage Snapshots) button to launch the Manage Snapshot window. Then click on the START HERE snapshot and press the Go To button. -7-
  8. 8. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.1.2 Taking Snapshots of the Virtual Machine (Optional) At any point in time when you are using the Virtual machine, if you wish to capture the current state of the virtual machine so that you can go back to the same state of the VM, you can take a snapshot of the Virtual Machine by doing the following. Click on the button on the top panel. Enter the name of the Snapshot and press on OK button to save the snapshot. To revert to an earlier snapshot later, click on the button. In the Manage Snapshot window, click on the snapshot you wish to revert to, and then click on the “Go to” button. -8-
  9. 9. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.1.3 (Optional) Networking Configuration on a Virtual Machine (Optional) This Virtual Machine uses NAT network by default. In brief words, it uses the IP address of the host machine to access the external network / Internet. This will be a one way network. Meaning that only the Virtual Machine can have access to the external network via the host machine; however, computers other than the host machine will not be able to access the Virtual Machine. If you would like the Virtual Machine to have its own IP address so that it is visible to outside network other than the host machine, you can set up the Bridged network connection, before turning on the virtual machine, go to Edit virtual machine settings > Device > Ethernet, choose "Bridged" then press OK. 4.1.4 Starting up the Virtual Machine To start up the virtual machine, press the button. You might be being asked rather you have moved or copied the virtual machine. Choose “I moved it” and click [OK] to continue. -9-
  10. 10. IBM® DB2 Express-C Virtual Appliance Installation Guide The following prompt may pop up. Select “No” to disable the attempt to connect to the virtual device floppy0. 4.2 Deployment of the DB2 Express-C Virtual Machine The following sections describe the detailed procedures on how to deploy a DB2 Express-C Virtual Machine. Please read carefully and follow the procedures to deploy your DB2 Express-C Virtual Machine. - 10 -
  11. 11. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.2.1 Logging on to the DB2 Express-C Virtual Machine 1. The VMware image should boot up and if everything is successful, you should see the following in the VMware window: 2. At this point, you can log into the DB2 EXPRESS-C 9.5 VIRTUAL APPLIANCE virtual appliance using the following root user password: Username: root Password: password 3. In the next screen, the License Agreements will appear. You must accept all statements and licenses that appear to use the DB2 EXPRESS-C 9.5 VIRTUAL APPLIANCE; otherwise the virtual appliance will halt. - 11 -
  12. 12. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. After accepting the license agreements, VMware Tools will start up. You will be prompted for the location of kernel files. Simply press ENTER to accept the default input [/lib/modules/2.6.16.60-0.21-smp/build/include]. 5. You will be asked on an experimental question from VMware tools. Select ‘yes/no’ to enable the feature on your virtual machine based on your preference. 6. When being asked if you want to change your guest X resolution, you can answer “yes” then choose the appropriate display size according to the display - 12 -
  13. 13. IBM® DB2 Express-C Virtual Appliance Installation Guide size of your host machine. After making your choice of display size of the virtual machine, you may see the VMware screen adjusting its size and flashes. It is a normal behaviour. Once VMware tool is done probing the correct display size, you will see the following YaST module starts. For 32 bit appliance, you may see two errors regarding non-existence of pcnet32 and vmxnet modules, they are normal behaviours. 4.2.2 System and Network Configuration After the VMware configuration tool is completed, the DB2 system configuration module will appear. This configuration module not only configures the hostname and network of the virtual system, it will also update any necessary changes to the DB2 environment. Note: If you would like to postpone the configuration of the network and applications, you can abort this configuration by pressing the tab key until the [Abort] button is highlighted and press Enter (alternatively you can press Alt + r). It is strongly recommended you do not abort this system and network configuration screen. If you choose to abort, you will need to manually invoke the configuration modules at a later time (See 6.1 Re-configuring System and Network Settings for details). 1. Once VMware tool is successfully configured, the following system configuration screen will appear as below. Enter the hostname, domain name, IP address, and netmask that will be used for the server. The gateway and DNS entries are optional. Please also enter the root password for the server and select [Next] to continue. - 13 -
  14. 14. IBM® DB2 Express-C Virtual Appliance Installation Guide Note: Please be sure to remember the root password set on the system and keep this password safe as the root user has all access to the files and configurations. A note on choosing a valid IP address on your virtual machine: By default, NAT uses the VMnet8 virtual network adapter on your host machine. To check which IP address you should be configured for the virtual machine, you should first check the VMnet8 settings on your VMware® using Virtual Network Editor: (Edit > Virtual Network Settings > NAT). From Virtual Network Editor, you will be able to find out the Gateway IP address for VMnet8. This IP address will be 192.168.###.2, where "###" is a random number set during your VMware® installation. Enter this Gateway IP address for the Gateway and DNS on your virtual machine. To assign a static IP address to your virtual machine, enter any addresses within the range of 192.168.###.3 to 192.168.###.127. Any IP addresses in the 192.168.###.128 to 192.168.###.253 range is reserved by VMware's DHCP, they should not be used for static IP addresses. In the following example, you should enter 192.168.238.2 as Gateway and DNS; and any number from 192.168.238.3 to 192.168.248.127 as static IP address. - 14 -
  15. 15. IBM® DB2 Express-C Virtual Appliance Installation Guide 2. Once system configuration is completed, the following screen will appear showing that the configuration is completed successfully. Select the [End] button and press Enter to end the system configuration module and continue onto the next configuration module. - 15 -
  16. 16. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.2.3 DB2 Configuration After you have successfully configured your system in the previous system configuration module, the DB2 Configuration module will appear. This DB2 configuration module will allow you to configure the DB2 environment on your Virtual Machine. Note: If you would like to postpone configuring DB2, you can abort this configuration screen by pressing the tab key until the [Abort] button is highlighted and press Enter (alternatively you can press Alt + r). If you choose to abort, you will need to manually invoke the configuration module at a later time (See 6.2 Re-configuring DB2 Settings Using the integrated db2config YaST2 module, you can re-configure the DB2 settings set originally during the initial deployment. WARNING By using this module, you will erase all existing DB2 instances on the system, including the ones manually created after initial deployment. If you are certain you want to perform this action, please following the below instructions. 1. To launch the db2config YaST2 module, login as root user. Open a terminal and enter the following command: - 16 -
  17. 17. IBM® DB2 Express-C Virtual Appliance Installation Guide # yast2 db2config 2. The db2config module will start and it will warn you that a successful configuration is detected on the system. If you are sure that you want to re- configure your system, press [Next] to continue. 3. Another warning screen will ask you to confirm that you wish to re-configure the DB2 settings. Warning: After pressing [Next] in this screen, the db2config module will erase all DB2 instances and configurations on the system. Press [Next] again ONLY if you are sure you wish to continue. - 17 -
  18. 18. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. The db2config module will stop DB2, and remove db2 users and instances. 5. Once the existing DB2 environment is cleared, the next screen will prompt you for user and password information for the DB2 instance, DB2 Administration Server (DAS), and the fenced user. Accept the suggested default users and - 18 -
  19. 19. IBM® DB2 Express-C Virtual Appliance Installation Guide enter only the password information or change the values by deselecting the checkbox at the bottom of the screen. Click [Next] after you have entered the required information. 6. When the process completes, you will be taken into a summary screen with the results of the reconfiguration. To exit the module, click [End]. - 19 -
  20. 20. IBM® DB2 Express-C Virtual Appliance Installation Guide 9. Since this is a reconfiguration of the DB2 settings, you will be provided with the option to create a database. If you wish to create a database at this point, choose a name for it. Otherwise, if you do not wish to create a database, simply leave the field empty and press [Next]. 10. The following screen will show the progress of the configuration. Please note that the DB2 configuration module do not create additional database partitions for the DB2 Virtual Appliance. Instead, a single partitioned environment will be - 20 -
  21. 21. IBM® DB2 Express-C Virtual Appliance Installation Guide created. 11. The last screen will present a summary of the database configuration stage and you can click [End] to finish. Re-configuring WASCE Settings for details). - 21 -
  22. 22. IBM® DB2 Express-C Virtual Appliance Installation Guide 1. You will be prompted to input the passwords for the DB2 users. Passwords for the DB2 instance owner, Database Administration Server (DAS) user, and fenced user must be specified. There is an option which allows you to make your own choice of the user and group names. To do so, uncheck the “Use default values” checkbox at the bottom. If non-default names are chosen, they must be no longer than 8 characters (setup will refuse to continue to the next screen until all inputs are valid). Once the user and password information are entered, select [Next] to continue. 2. DB2 will be configured based on the settings specified. The next screen will display the progress of the DB2 Configuration. - 22 -
  23. 23. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. Once the configuration is completed, press [End] to exit the DB2 configuration module. The DB2 instance created will be using the port number 50001. - 23 -
  24. 24. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.2.4 Database creation screen 1. The database creation screen will pop up next. At this stage, you can optionally create your database. If you would like to create a database now, enter a database name in the field. If you prefer to create the database at a later time, leave the field blank. In either case press [Next] to continue. 2. The next screen will show the progress of the database creation. Note that although the first progress is called “Create Database Partitions”, no multiple database partitions will be created on the Virtual Appliance. In fact, the database will be created in a SINGLE partition. Please wait patiently while the configuration is in progress. - 24 -
  25. 25. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. When the database is successfully created, Press [End] to exit the database creation screen. You will notice that only the default tablespaces are created in the database. This is because additional tablespace creation would significantly extend the length of the deployment time. If you wish to create additional database/tablespaces, creation scripts are created for your convenience. Mark down the location of these scripts and you will be able to create the desired database objects at a later time. - 25 -
  26. 26. IBM® DB2 Express-C Virtual Appliance Installation Guide 4.2.5 WASCE Configuration After you have successfully configured your DB2 environment, the WASCE Configuration module will appear. This WASCE configuration module will deploy a sample Day Trader Application on your Virtual Machine. By default, a WASCE samples bundle is installed with WASCE on your Virtual Appliance. The WASCE samples bundle are provided to help you: ► Exercise and evaluate the WebSphere Application Server Community Edition ► Build experience and practice deploying Java EE assets ► Use as templates for developing and deploying your own Java EE assets Out of the samples bundle, there is a useful sample application called DayTrader which emulates a stock trading storyline. Using the DayTrader sample application, you can look at your portfolio, get quotes, as well as buy and sell stocks. The sample application deployment is via EAR file. DayTrader is an example of a Java EE enterprise application that uses security, message queues, and Enterprise JavaBeans (EJBs). This example uses a number of different Java EE assets and contains a deployment plan that can be used as a model when developing a deployment plan for your own enterprise application. - 26 -
  27. 27. IBM® DB2 Express-C Virtual Appliance Installation Guide In addition, this sample can be used to exercise the server when you want to evaluate the performance of different platforms, configurations, or Java EE implementation options. In the WASCE module, it will deploy the DayTrader sample application for your convenience. Note: If you would like to postpone deploying the WASCE sample application, you can abort this configuration screen by pressing the tab key until the [Abort] button is highlighted and press Enter (alternatively you can press Alt + r). This module can also be manually invoked at a later time (See 6.2 Re-configuring DB2 Settings Using the integrated db2config YaST2 module, you can re-configure the DB2 settings set originally during the initial deployment. WARNING By using this module, you will erase all existing DB2 instances on the system, including the ones manually created after initial deployment. If you are certain you want to perform this action, please following the below instructions. 7. To launch the db2config YaST2 module, login as root user. Open a terminal and enter the following command: # yast2 db2config 8. The db2config module will start and it will warn you that a successful configuration is detected on the system. If you are sure that you want to re- configure your system, press [Next] to continue. - 27 -
  28. 28. IBM® DB2 Express-C Virtual Appliance Installation Guide 9. Another warning screen will ask you to confirm that you wish to re-configure the DB2 settings. Warning: After pressing [Next] in this screen, the db2config module will erase all DB2 instances and configurations on the system. Press [Next] again ONLY if you are sure you wish to continue. - 28 -
  29. 29. IBM® DB2 Express-C Virtual Appliance Installation Guide 10. The db2config module will stop DB2, and remove db2 users and instances. 11. Once the existing DB2 environment is cleared, the next screen will prompt you for user and password information for the DB2 instance, DB2 Administration Server (DAS), and the fenced user. Accept the suggested default users and - 29 -
  30. 30. IBM® DB2 Express-C Virtual Appliance Installation Guide enter only the password information or change the values by deselecting the checkbox at the bottom of the screen. Click [Next] after you have entered the required information. 12. When the process completes, you will be taken into a summary screen with the results of the reconfiguration. To exit the module, click [End]. - 30 -
  31. 31. IBM® DB2 Express-C Virtual Appliance Installation Guide 12. Since this is a reconfiguration of the DB2 settings, you will be provided with the option to create a database. If you wish to create a database at this point, choose a name for it. Otherwise, if you do not wish to create a database, simply leave the field empty and press [Next]. 13. The following screen will show the progress of the configuration. Please note that the DB2 configuration module do not create additional database partitions for the DB2 Virtual Appliance. Instead, a single partitioned environment will be - 31 -
  32. 32. IBM® DB2 Express-C Virtual Appliance Installation Guide created. 14. The last screen will present a summary of the database configuration stage and you can click [End] to finish. Re-configuring WASCE Settings for details). - 32 -
  33. 33. IBM® DB2 Express-C Virtual Appliance Installation Guide 1. When the WASCE module is started, it will prompt you if you want to continue the DayTrader Sample Application deployment. If you do not wish to deploy the DayTrader sample, select No; otherwise select Yes and click [Next] to continue. 2. If you have chosen Yes to continue the DayTrader deployment, the following screen will appear prompting for the DB2 instance name and password. Since the DayTrader sample application is associated with a DB2 database named “tradedb”, the instance information will be used to create and access the sample tradedb database. By default, the default DB2 instance name “db2inst1” is pre-selected. If you wish to choose another DB2 instance for tradedb creation, you can de-select the “Use default values” option and choose the preferred DB2 instance under Instance user name. Enter the name and password for the DB2 instance. Press [Next] to continue. - 33 -
  34. 34. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. Once you have pressed [Next] to continue, the following progress screen will appear. Please wait patiently while the DayTrader sample is being deployed. - 34 -
  35. 35. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. Once the DayTrader sample is deployed successfully, the result screen will appear. Review the notes and press [End] to finish the module. 5. The DB2 Express-C 9.5 Virtual Appliance virtual machine is now ready for use. The server will go to a login screen, where the user can login as desired. To login as db2 instance user, enter the previously configured db2 instance as username and enter the password as you specified in the configuration screen earlier. - 35 -
  36. 36. IBM® DB2 Express-C Virtual Appliance Installation Guide The deployment of the DB2 Express-C 9.5 Virtual Appliance is now complete. - 36 -
  37. 37. IBM® DB2 Express-C Virtual Appliance Installation Guide 5. Working with Your Installed System Congratulations on completing the deployment of the DB2 Express-C Virtual Appliance. Now that you have completed the deployment of DB2 Express-C solution on a Virtual Machine, we will point you to where to find the components you want to work with. The DB2 Express-C Virtual Appliance is available on Novell® SUSE® Linux Enterprise Server 10 SP2. There are several shortcut links on your Desktop once you log on as the root user: 1. DB2 Express C First Steps This browser link will take you to the DB2 Express-C introduction and tutorials. This is a good starting point for first time DB2 users. 2. DB2 Information Center This is an external browser link, which will take you to the online DB2 9.5 Information Center for Linux, UNIX, and Windows. (Internet connection is required to access the link) 3. DB2 Monitoring Console PHP web application which allows you to easily monitor DB2 for Linux, Unix, and Windows database. 4. DB2 Control Center* [*Available when logged on as DB2 instance user] A Control Center shortcut is created on a DB2 instance user’s desktop. Use the Control Center to manage and administrate systems, DB2® database instances, database objects such as tables and views. From the Control Center, you can also open other centers and tools to help you optimize queries, jobs, scripts, create stored procedures, and work with DB2 commands…etc. 5. WAS Community Edition A web administrative console which allows you to configure and start deploying WASCE applications. 6. WASCE Day Trader Sample Application Several J2EE assets are included in with the virtual appliance to help you exercise and build experiences using WebSphere Application Server Community Edition. During the initialization of the virtual machine, a Daytrader sample application is deployed. Daytrader provides a sample application that emulates a stock trading storyline. You can look at your portfolio, get quotes as well as buy and sell stocks. Use this sample if you need an example of a J2EE enterprise application that uses security, message queues, and enterprise JavaBeans (EJBs). This example uses a number of different J2EE assets and contains a development plan that can be used as a model when development a deployment plan for your own enterprise application. - 37 -
  38. 38. IBM® DB2 Express-C Virtual Appliance Installation Guide 7. WASCE V2.0 Documentation A web shortcut view WebSphere Application Server Community Edition v2.0 documentation online. 5.1 Starting and Stopping DB2 service In the deployed DB2 Express-C Virtual Appliance environment, a package is installed automatically which allows user to easily start and stop DB2/WASCE and setup required kernel environment with one single command. 5.1.1 Starting and Stopping DB2 with rcdb2 The rcdb2 tool is pre-installed on the Virtual Appliance for your convenience. With one single rcdb2 command, you are able to: ► check the current status of DB2 Administration Server and instances ► setup required kernel parameters and start DB2 and activate all existing DB2 databases ► stop DB2 services all at once The rcdb2 tool is registered in the default SLES OS startup and stop sequence, so that when the system is shutdown and started up, DB2 services will be stopped and started up automatically. This can eliminate the user’s need to stop DB2 manually before turning off the machine, or start DB2 services manually after every system bootup. To check the current status of DB2, run the following command with the root user: # rcdb2 status DAS: running Instance db2inst1 ( 50001): running To stop DB2, run the following command with the root user: # rcdb2 stop Stopping DAS: done Stopping instance db2inst1 done To start DB2, run the following command with the root user: # rcdb2 start Starting DAS: done Starting instance db2inst1 done Activating TESTDB done Activating TRADEDB done - 38 -
  39. 39. IBM® DB2 Express-C Virtual Appliance Installation Guide Every time rcdb2 start is executed, it will verify and set the required kernel parameters to run DB2 on the system. When the kernel parameters are verified in place, the tool will start DB2 Administration Server as well as every DB2 instances and databases on the system. To restart DB2, run the following command with the root user: # rcdb2 restart Stopping DAS: done Stopping instance db2inst1 done Starting DAS: done Starting instance db2inst1 done Activating TESTDB done Activating TRADEDB done 5.1.2 Kernel Parameter settings in rcdb2 In a default Linux environment, the default kernel parameter values are not sufficient when running DB2 database on a system. The DB2 Express-C Virtual Appliance customized rcdb2 start/stop script updates the recommended kernel parameters for a virtualized DB2 server. By default, the DB2 Express-C Virtual Appliance customized rcdb2 start/stop script updates the following kernel parameters every time rcdb2 start/restart is executed. kernel.shmmax = <90%_of_physical_memory_on_system> kernel.shmall = <90%_of_physical_memory_on_system_in_pages> kernel.shmmni = 4096 kernel.msgmni = 1024 kernel.msgmnb = 65536 kernel.msgmax = 65536 kernel.sem = 250 256000 32 4096 vm.swappiness = 0 vm.dirty_ratio = 10 vm.dirty_background_ratio = 5 fs.file-max = 262144 IMPORTANT It is strongly recommended to keep the default DB2 kernel parameter settings. Modifying any default DB2 kernel parameters may result in DB2 running on the system not able to perform properly. If you are certain and would still like to modify the kernel parameters, execute the following command to modify the kernel parameters temporarily. Note that you must have root authority to modify kernel parameters. - 39 -
  40. 40. IBM® DB2 Express-C Virtual Appliance Installation Guide # /sbin/sysctl -w <kernel_parameter_name>=<new_value> For example, if you would like to set the value of kernel.msgmax to 65536: # /sbin/sysctl –w kernel.msgmax=65536 NOTE: The kernel parameters will only be modified temporarily. Every time the system is rebooted, or when rcdb2 is start/restart is executed, the kernel parameters will be updated to the above default virtualized DB2 environment settings. 5.1.3 DB2 Registry and DBM/DB Configuration Settings During the initial DB2 configuration module, certain Database Manager settings have been pre-configured for your DB2 environment. These settings are configured based on expert recommendations for easy administration. However, if you have specific business requirements for your DB2 environment, you may change the parameters as required. 5.1.3.1 DB2 Profile Registry Parameters db2set DB2_EXTENDED_OPTIMIZATION=ON db2set DB2_ANTIJOIN=YES db2set DB2COMM=tcpip db2set DB2_PARALLEL_IO=*:6 db2set DB2RSHCMD=/usr/bin/ssh 5.1.3.2 DB2 Fault Monitor The DB2 Fault Monitor (db2fm) is turned off on the Virtual Appliance by default. 5.1.3.3 Database Manager Configuration Parameters DFTDBPATH /db2fs JAVA_HEAP_SZ 2048 INSTANCE_MEMORY AUTOMATIC All other Database Manager Configuration Parameters are set to the DB2 default values. - 40 -
  41. 41. IBM® DB2 Express-C Virtual Appliance Installation Guide 5.1.3.4 Database Configuration Parameters If you have chosen to create a database in the DB2 configuration module (Section Error! Reference source not found. Error! Reference source not found.), or you have used the “/home/${DB2INSTANCE}/bin/createDatabase” script to create a database, the following database configuration parameters would have been applied automatically: auto_maint ON; auto_db_backup OFF; auto_tbl_maint ON; auto_runstats ON; auto_reorg ON; All other database parameters are set to the DB2 default values. 5.1.3.5 Displaying DB2 profile registry / Configuration parameters To display a list of configured DB2 profile registry parameters: db2set –all To display a list of configured DB2 Database Manager Configuration parameters: db2 attach to <DB2INSTANCE> db2 get dbm cfg show detail To display a list of configured DB2 Database Configuration parameters: db2 connect to <DBNAME> db2 get db cfg show detail 5.1.3.6 Modifying DB2 profile registry / Configuration parameters If any of the above parameters do not fit your business requirements, you may change the parameters using the following utilities. To update DB2 profile registry parameters: - 41 -
  42. 42. IBM® DB2 Express-C Virtual Appliance Installation Guide db2set <REGISTRY_PARAMETER>=<VALUE> To update Database Manager (DBM) configuration parameters: db2 update dbm cfg using <PARAM_NAME> <VALUE> To update Database (DB) configuration parameters: db2 update db cfg using <PARAM_NAME> <VALUE> 5.1.4 Database and Tablespace Creation Utilities Once you have successfully deployed the DB2 Express Virtual Appliance, you will be provided with scripts for creating additional databases and tablespaces. The location of the scripts is in the DB2 instance’s home directory under the bin directory: /home/<DB2INSTANCE>/bin/createDatabase /home/<DB2INSTANCE>/bin/createTablespaces 5.1.4.1 createDatabase script The createDatabase script is executed if you have chosen to create a database in the DB2 configuration module (Section Error! Reference source not found. Error! Reference source not found.). The database created will have the following attributes: ► Storage method: Automatic storage database using database/storage path on /db2fs ► Database will be created under: /db2fs/<DB2INSTANCE>/NODE0000/<DBNAME> ► Database partitions: 0 ► Buffer Pools: A bufferpool named bpool8k is created by default with page size of 8 kB. If you wish to create an additional database, you can create a database using the pre- configured createDatabase script following the following procedures: 1. Login as DB2 instance user - 42 -
  43. 43. IBM® DB2 Express-C Virtual Appliance Installation Guide db2server:~ # su – db2inst1 2. Change directory to /home/<DB2INSTANCE>/bin directory: db2inst1@db2server:~> cd bin 3. Execute the createDatabase script from the bin directory: db2inst1@db2server:~/bin> ./createDatabase <DATABASE_NAME> 4. When the database has successfully created, you should see the following message: db2inst1@c4000:~/bin> ./createDatabase TESTDB [*] Creating database TESTDB... OK [*] Creating db partition groups ... OK [*] Creating buffer pools... OK [*] Configuring database... OK [*] Database created and configured successfully. [*] Restarting instance... OK [*] Database creation complete. 5.1.4.2 createTablespaces script Once you have created a database in the DB2 configuration module (Section Error! Reference source not found. Error! Reference source not found.) or manually using the createDatabase script, you are ready to use the createTablespaces script to create the data, index, and temporary tablespaces for your database. The createTablespaces script calculates the size of all data, index, and temporary tablespaces based on the space available and recommended certain sizes. If you do not wish to create the tablespaces based on the recommended sizes, you can optionally provide your own size preferences for individual tablespaces. Note: The tablespaces creation will take a long time to complete. Therefore, the tablespace creation step is skipped even if you have chosen to create a database in the DB2 configuration module (Section Error! Reference source not found. Error! Reference source not found.). Note: Please note that the provided createTablespaces script depends on the provided createDatabase script. The createTablespace script will not work If you have not created a database using either the DB2 Configuration tool (Section Error! Reference source not found. Error! Reference source not found.) or manually executed the - 43 -
  44. 44. IBM® DB2 Express-C Virtual Appliance Installation Guide createDatabase script (Section 5.1.4.1 createDatabase script). The createTablespaces script will perform the following: ► Calculates available space across database containers. ► Creates three tablespaces of different sizes based on recommended calculated sizings: o DATA tablespace: available container space divided by 3 o INDEX tablespace: available container space divided by 3 o TEMP tablespace: available container space divided by 9 ► All tablespaces will be created in page size of 8 kB, using bufferpool bpool8k. ► Remaining container space will be left as free physical space, which can be used for storing database backups. To create pre-configure tablespaces using the createTablespace script, please follow the following steps: 1. Login as DB2 instance user db2server:~ # su – db2inst1 2. Change directory to /home/<DB2INSTANCE>/bin directory: ~> cd bin 3. Execute the createDatabase script from the bin directory: ~/bin> ./createTablespaces <DATABASE_NAME> 4. The recommended tablespace sizing will be displayed. Enter Y to accept the default sizing or N to provide your own sizing preferences. ~/bin> ./createTablespaces TESTDB Please verify the following information. Size of the DATA tablespace per partition: 12GB Size of the INDEX tablespace per partition: 12GB Size of the TEMP tablespace per partition: 4GB Is this correct? (Y/N) - 44 -
  45. 45. IBM® DB2 Express-C Virtual Appliance Installation Guide 5. The tablespaces will then be created. The createTablespaces progress may take several hours to finish. Please wait patiently for the tablespaces to get created. 5.1.5 Starting and stopping WASCE service using rcwasce To check the current status of WebSphere Application Server Community Edition, run the following command with the root user: # rcwasce status Checking for IBM WebSphere Application Server Community Edition 2.0.0.2 Status of WASCE running To stop WebSphere Application Server, run the following command with the root user: # rcwasce stop Stopping IBM WebSphere Application Server Community Edition 2.0.0.2 Stopping WASCE done To start WebSphere Application Server, run the following command with the root user: # rcwasce start Starting IBM WebSphere Application Server Community Edition 2.0.0.2 Starting WASCE done To restart WebSphere Application Server, run the following command with the root user: # rcwasce restart Stopping IBM WebSphere Application Server Community Edition 2.0.0.2 Stopping WASCE done Starting IBM WebSphere Application Server Community Edition 2.0.0.2 Starting WASCE done - 45 -
  46. 46. IBM® DB2 Express-C Virtual Appliance Installation Guide 5.2 DB2 Monitoring Console Another great tool that comes with the Virtual Appliance is the DB2 Monitoring Console. In order to access the DB2 Monitoring Console, the system has to meet the following requirements: • Apache2 and PHP5 needs to be running. To verify, open a command prompt and run “rcapache2 status” as root to verify the status of the service. If the service is not running, start apache2 by executing “rcapache2 restart”. # rcapache2 status Checking for httpd2: running # rcapache2 restart Syntax OK Starting httpd2 (prefork): done • DB2 needs to be running. To verify if DB2 is running, open a command prompt and run “rcdb2 status” as root to verify the status of the DB2 processes and instance. If DB2 is not running, start DB2 by executing “rcdb2 restart”. # rcdb2 status DAS: running Instance db2inst1 ( 50001): running # rcdb2 restart Starting DAS: done Starting instance db2inst1 done Once all of the above requirements are met, follow the instructions below to start using DB2 Monitoring Console. 1. Double click on the “DB2 Monitoring Console” icon on the desktop to start the console. You can also reach the “DB2 Monitoring Console” by pointing to the following URL in a web browser: http://<hostname>/DMC/index.html 2. The DB2 Monitoring Console will open in a Firefox window. Click on in the upper right corner to connect to a database. 3. If you would like to connect to a database, in the New Connection section, enter your database information then click on the Connect button. (The port number for the DB2 instance db2inst1 is set to 50001 by default) - 46 -
  47. 47. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. When the DB2 Monitoring Console is connected to a database, a server details page will appear on the screen as below. Please feel free to browse the rest of the functions on the left panel. Enjoy! For latest information, updates, and fixes to the DB2 Monitoring console, please refer to the http://sourceforge.net/projects/db2mc/ website. - 47 -
  48. 48. IBM® DB2 Express-C Virtual Appliance Installation Guide 5.3 DB2 Control Center To launch the DB2 Control Center, login as a DB2 instance user, then click on the DB2 Control Center icon: You can also launch the DB2 control center from the command line by typing the following command by a DB2 instance user: db2inst1@db2expc:~> db2cc & From within DB2 control center, you can also launch other center and tools from there. To do so, launch DB2 Control Center, then click on Tools on the top panel menu. To start accessing your database, click on All Databases on the left panel, then click on the database you would like to connect. Click on Connect in the right lower panel to start connecting to the database. - 48 -
  49. 49. IBM® DB2 Express-C Virtual Appliance Installation Guide For your information, the DB2 control center binary file is stored in: /opt/ibm/db2/V9.5/bin/db2cc 5.4 WebSphere Application Server Community Edition Administration Console A desktop shortcut to the WAS CE Administration console is created for your convenience. Perform the following steps to start the WAS CE Administration console: 1. Before starting the WAS CE Administration console, verify that DB2 and WAS CE service is up and running: Run the following commands with the root user: # rcdb2 status DAS: running Instance db2inst1 ( 50001): running - 49 -
  50. 50. IBM® DB2 Express-C Virtual Appliance Installation Guide # rcwasce status Checking for IBM WebSphere Application Server Community Edition 2.0.0.2 Status of WASCE running 2. To start the WAS CE Administration console, double click on the desktop icon on root’s desktop: 3. The following page will appear. Click on “Administrative Console” and logon using the following default user/password to start using WAS CE. User: system Password: manager 4. You can also start the console page by manually starting Mozilla firefox, and enter “http://localhost:8080/” in the address field. 5. When you are logged in, you will see the following welcome screen. Start using WAS CE by clicking on different links under the Console Navigation menu on the - 50 -
  51. 51. IBM® DB2 Express-C Virtual Appliance Installation Guide left panel. 6. Navigate to the WAS CE documentation page at http://publib.boulder.ibm.com/wasce/V2.0.0/en/index.html if you want to learn more about WAS CE. 5.5 Daytrader sample application During the virtual machine initialization, a WAS CE sample application “Day trader” has been deployed for you to try out an example of deployed Java EE enterprise application. Daytrader provides a sample application that emulates a stock trading storyline. You can look at your portfolio, get quotes as well as buy and sell stocks. Deployment is via EAR file located in /opt/ibm/WebSphere/AppServerCommunityEdition/samples/applications /daytrader/modules/ear/target/daytrader-ear-2.0.0.2.ear. Use this sample if you need an example of a Java EE enterprise application that uses security, message queues, and Enterprise JavaBeans (EJBs). This example uses a number of different Java EE assets and contains a deployment plan that can be used as a model when developing a deployment plan for your own enterprise application. The deployment plan is located in: /opt/ibm/WebSphere/AppServerCommunityEdition/samples/applications /daytrader/plans/dayTrader-db2-9.5-XA-plan.xml - 51 -
  52. 52. IBM® DB2 Express-C Virtual Appliance Installation Guide In addition, use this sample to exercise the server when you want to evaluate the performance of different platforms, configurations, or Java EE implementation options. The Daytrader sample application has an associated database to store application data. The database is called “tradedb” and is created using the default instance which you have configured during the DB2 configuration module (4.2.3 DB2 Configuration After you have successfully configured your system in the previous system configuration module, the DB2 Configuration module will appear. This DB2 configuration module will allow you to configure the DB2 environment on your Virtual Machine. Note: If you would like to postpone configuring DB2, you can abort this configuration screen by pressing the tab key until the [Abort] button is highlighted and press Enter (alternatively you can press Alt + r). If you choose to abort, you will need to manually invoke the configuration module at a later time (See 6.2 Re-configuring DB2 Settings Using the integrated db2config YaST2 module, you can re-configure the DB2 settings set originally during the initial deployment. WARNING By using this module, you will erase all existing DB2 instances on the system, including the ones manually created after initial deployment. If you are certain you want to perform this action, please following the below instructions. 13. To launch the db2config YaST2 module, login as root user. Open a terminal and enter the following command: # yast2 db2config 14. The db2config module will start and it will warn you that a successful configuration is detected on the system. If you are sure that you want to re- configure your system, press [Next] to continue. - 52 -
  53. 53. IBM® DB2 Express-C Virtual Appliance Installation Guide 15. Another warning screen will ask you to confirm that you wish to re-configure the DB2 settings. Warning: After pressing [Next] in this screen, the db2config module will erase all DB2 instances and configurations on the system. Press [Next] again ONLY if you are sure you wish to continue. - 53 -
  54. 54. IBM® DB2 Express-C Virtual Appliance Installation Guide 16. The db2config module will stop DB2, and remove db2 users and instances. 17. Once the existing DB2 environment is cleared, the next screen will prompt you for user and password information for the DB2 instance, DB2 Administration Server (DAS), and the fenced user. Accept the suggested default users and - 54 -
  55. 55. IBM® DB2 Express-C Virtual Appliance Installation Guide enter only the password information or change the values by deselecting the checkbox at the bottom of the screen. Click [Next] after you have entered the required information. 18. When the process completes, you will be taken into a summary screen with the results of the reconfiguration. To exit the module, click [End]. - 55 -
  56. 56. IBM® DB2 Express-C Virtual Appliance Installation Guide 15. Since this is a reconfiguration of the DB2 settings, you will be provided with the option to create a database. If you wish to create a database at this point, choose a name for it. Otherwise, if you do not wish to create a database, simply leave the field empty and press [Next]. 16. The following screen will show the progress of the configuration. Please note that the DB2 configuration module do not create additional database partitions for the DB2 Virtual Appliance. Instead, a single partitioned environment will be - 56 -
  57. 57. IBM® DB2 Express-C Virtual Appliance Installation Guide created. 17. The last screen will present a summary of the database configuration stage and you can click [End] to finish. Re-configuring WASCE Settings for details). - 57 -
  58. 58. IBM® DB2 Express-C Virtual Appliance Installation Guide 4. You will be prompted to input the passwords for the DB2 users. Passwords for the DB2 instance owner, Database Administration Server (DAS) user, and fenced user must be specified. There is an option which allows you to make your own choice of the user and group names. To do so, uncheck the “Use default values” checkbox at the bottom. If non-default names are chosen, they must be no longer than 8 characters (setup will refuse to continue to the next screen until all inputs are valid). Once the user and password information are entered, select [Next] to continue. 5. DB2 will be configured based on the settings specified. The next screen will display the progress of the DB2 Configuration. - 58 -
  59. 59. IBM® DB2 Express-C Virtual Appliance Installation Guide 6. Once the configuration is completed, press [End] to exit the DB2 configuration module. The DB2 instance created will be using the port number 50001. - 59 -
  60. 60. IBM® DB2 Express-C Virtual Appliance Installation Guide 5.5.1 Database creation screen 6. The database creation screen will pop up next. At this stage, you can optionally create your database. If you would like to create a database now, enter a database name in the field. If you prefer to create the database at a later time, leave the field blank. In either case press [Next] to continue. - 60 -
  61. 61. IBM® DB2 Express-C Virtual Appliance Installation Guide 7. The next screen will show the progress of the database creation. Note that although the first progress is called “Create Database Partitions”, no multiple database partitions will be created on the Virtual Appliance. In fact, the database will be created in a SINGLE partition. Please wait patiently while the configuration is in progress. - 61 -
  62. 62. IBM® DB2 Express-C Virtual Appliance Installation Guide 8. When the database is successfully created, Press [End] to exit the database creation screen. You will notice that only the default tablespaces are created in the database. This is because additional tablespace creation would significantly extend the length of the deployment time. If you wish to create additional database/tablespaces, creation scripts are created for your convenience. Mark down the location of these scripts and you will be able to create the desired database objects at a later time. - 62 -
  63. 63. IBM® DB2 Express-C Virtual Appliance Installation Guide WASCE Configuration) To start exploring the Daytrader application, double-click on the “WASCE Daytrader sample application” desktop icon on root user’s desktop. You can also open the Daytrader application by opening firefox manually, and enter http://localhost:8080/daytrader/ in the address field. You can start configuring the sample application by clicking on the Configuration tab in the application interface. - 63 -
  64. 64. IBM® DB2 Express-C Virtual Appliance Installation Guide There are lots of other WAS CE samples also available in the /opt/ibm/WebSphere/AppServerCommunityEdition/samples/ directory. Refer to http://publib.boulder.ibm.com/wasce/V2.0.0/en/samples.html for more information about other WAS CE samples. 5.6 Installed Software Location DB2 9.5 is installed in /opt/ibm/db2/V9.5 directory on your server. The default port number for your instance is 50001. WebSphere Application Server Community Edition 2.0.0.2 is installed in /opt/ibm/WebSphere/AppServerCommunityEdition directory on your server. WAS CE samples are installed in /opt/ibm/WebSphere/AppServerCommunityEdition/samples directory on your server. DB2 Monitoring Console is installed in /srv/www/htdocs/DMC directory on your server. Start using all the installed IBM software and enjoy! - 64 -
  65. 65. IBM® DB2 Express-C Virtual Appliance Installation Guide 6. Re-configuring Your System Once you have deployed your DB2 Express-C Virtual Appliance, you are given the option to re-configure your system by means of the fully-integrated into SLES10 YaST2 modules for system, DB2 Configuration settings. WARNING The actions discussed here are not recommended for successfully deployed working systems as these modules will completely erase any existing data and configurations. 6.1 Re-configuring System and Network Settings You can re-configure your system and network settings via the db2sysconfig YaST2 module. If you are certain you want to perform this action, please following the below instructions. 1. Open a terminal window on your system and enter following command: # yast2 db2sysconfig 2. The db2sysconfig module will start and it will warn you that a successful configuration is detected on the system. If you are sure that you want to re- configure your system, press [Next] to continue. - 65 -
  66. 66. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. Another warning screen will ask you to confirm that you wish to re-configure the system settings. Press [Next] again if you wish to continue. 4. The next screen will ask you to enter system information such as hostname, domain, IP Address, Netmask, DNS, Gateway and root password. Press [Next] when you are ready to continue. - 66 -
  67. 67. IBM® DB2 Express-C Virtual Appliance Installation Guide 5. At this point, the system configurations that existed on the system prior to you launching the module will be erased and the new settings will be applied. Wait until the process has completed - 67 -
  68. 68. IBM® DB2 Express-C Virtual Appliance Installation Guide 6. The final screen will present you with a summary of the configurations. Your system is now re-configured according to your specifications. Remember to adapt these changes in any applications which use the changed hostname, networking information, and/or root password. Press [End] to exit the module. - 68 -
  69. 69. IBM® DB2 Express-C Virtual Appliance Installation Guide 6.2 Re-configuring DB2 Settings Using the integrated db2config YaST2 module, you can re-configure the DB2 settings set originally during the initial deployment. WARNING By using this module, you will erase all existing DB2 instances on the system, including the ones manually created after initial deployment. If you are certain you want to perform this action, please following the below instructions. 19. To launch the db2config YaST2 module, login as root user. Open a terminal and enter the following command: # yast2 db2config 20. The db2config module will start and it will warn you that a successful configuration is detected on the system. If you are sure that you want to re- configure your system, press [Next] to continue. - 69 -
  70. 70. IBM® DB2 Express-C Virtual Appliance Installation Guide 21. Another warning screen will ask you to confirm that you wish to re-configure the DB2 settings. Warning: After pressing [Next] in this screen, the db2config module will erase all DB2 instances and configurations on the system. Press [Next] again ONLY if you are sure you wish to continue. - 70 -
  71. 71. IBM® DB2 Express-C Virtual Appliance Installation Guide 22. The db2config module will stop DB2, and remove db2 users and instances. 23. Once the existing DB2 environment is cleared, the next screen will prompt you for user and password information for the DB2 instance, DB2 Administration Server (DAS), and the fenced user. Accept the suggested default users and - 71 -
  72. 72. IBM® DB2 Express-C Virtual Appliance Installation Guide enter only the password information or change the values by deselecting the checkbox at the bottom of the screen. Click [Next] after you have entered the required information. 24. When the process completes, you will be taken into a summary screen with the results of the reconfiguration. To exit the module, click [End]. - 72 -
  73. 73. IBM® DB2 Express-C Virtual Appliance Installation Guide 18. Since this is a reconfiguration of the DB2 settings, you will be provided with the option to create a database. If you wish to create a database at this point, choose a name for it. Otherwise, if you do not wish to create a database, simply leave the field empty and press [Next]. 19. The following screen will show the progress of the configuration. Please note that the DB2 configuration module do not create additional database partitions for the DB2 Virtual Appliance. Instead, a single partitioned environment will be - 73 -
  74. 74. IBM® DB2 Express-C Virtual Appliance Installation Guide created. 20. The last screen will present a summary of the database configuration stage and you can click [End] to finish. - 74 -
  75. 75. IBM® DB2 Express-C Virtual Appliance Installation Guide 6.3 Re-configuring WASCE Settings Using the customized wasceconfig YaST2 module, you can re-deploy the DayTrader sample application deployed originally during the initial deployment. WARNING By using this module, you will undeploy the Daytrader sample application as well as all DayTrader data created after the initial deployment. If you are certain you want to perform this action, please following the below instructions. 1. To launch the wasceconfig YaST2 module, login as root user. Open a terminal and enter the following command: # yast2 wasceconfig 2. The wasceconfig module will start and it will warn you that a successful DayTrader deployment is detected on the system. If you are sure that you want to re-deploy the DayTrader sample, press [Next] to continue. - 75 -
  76. 76. IBM® DB2 Express-C Virtual Appliance Installation Guide 3. Another warning screen will ask you to confirm that you wish to continue re- deploying the DayTrader sample application. Warning: After pressing [Next] in this screen, the wasceconfig module will erase all existing DayTrader data on the system. Press [Next] again ONLY if you are sure you wish to continue. 4. The wasceconfig module will un-deploy the DayTrader sample and stop the WASCE service. 5. Once the existing DayTrader sample is erased, it will prompt if you want to continue deploying a new DayTrader sample application. Select (Yes/No) according to your preference and click [Next]. - 76 -
  77. 77. IBM® DB2 Express-C Virtual Appliance Installation Guide 6. If you have chosen Yes in previous screen, you will be asked to provide a DB2 instance user name and password. The DB2 instance access info is needed to create the associated database for the DayTrader application. The default DB2 instance (db2inst1) has been pre-selected for you. If you wish to choose another DB2 instance, uncheck the “Use default values” checkbox and select the correct DB2 instance user according to your preference. When you have entered the information, click [Next] to continue. 7. The next screen will show the progress of the DayTrader deployment. Please wait patiently while configuration is in process. - 77 -
  78. 78. IBM® DB2 Express-C Virtual Appliance Installation Guide 8. The following screen will appear when the DayTrader application is deployed successfully. When you have finished reviewing the notes, press [End] to end the module. - 78 -
  79. 79. IBM® DB2 Express-C Virtual Appliance Installation Guide 7. Additional Information Note that the packages contained on this page, as well as the contents of this DB2 Express-C Virtual Appliance material are for demonstration only. It is subject to change without notice. VMware Player 2.0 or VMware Workstation 5.5 is required to run the images. You may find VMware Player on the VMware website. 7.1 Feedback Thank you for using DB2 Express-C Virtual Appliance. We welcome your feedback about your experience on the DB2 Express-C Virtual Appliance. If you notice anything not working correctly, or would like to comment on your experience on the DB2 Virtual Appliance, please send your feedback to db2x@ca.ibm.com, enter "DB2 Express-C Virtual Appliance" in the subject line. For technical questions on DB2 Express-C, please refer to the DB2 Express-C forum website. - 79 -
  80. 80. © Copyright IBM Corporation 2008 All Rights Reserved. IBM Canada 8200 Warden Avenue Markham, ON L6G 1C7 Canada Printed in Canada 07/22/2008 IBM, IBM (logo), DB2, WebSphere are trademarks or registered The information in this publication is provided AS IS without trademarks of International Business Machines Corporation in the warranty. Such information was obtained from publicly available United States, other countries, or both. sources, is current as of January 2008, and is subject to change. Any performance data included in the paper was obtained in the Novell and SUSE are registered trademarks of Novell, inc. in the specific operating environment and is provided as an illustration. United States, other countries, or both. SUSE Linux Enterprise Performance in other operating environments may vary. More Server is provided and licensed directly to you by Novell. specific information about the capabilities of products described should be obtained from the suppliers of those products. Linux is a trademark of Linus Torvalds in the United States, other countries, or both. UNIX is a registered trademark of The Open Group in the United States, other countries, or both Windows is a trademark of Microsoft Corporation in the United States, other countries, or both. Nagios and the Nagios logo are trademarks or registered trademarks of Nagios Enterprises in the United States, other countries, or both. Other company, product, or service names may be trademarks or service marks of others. References in this publication to IBM products or services do not imply that IBM intends to make them available in all countries in which IBM operates. 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. This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice. Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products.

×