WebSphere brand IBM WebSphere Presence Server, Version 7.0

Creating the Presence Server database for DB2

Before installing the Presence Server product, you must configure database for use by the application.

Before you begin
Before you begin, the following software should be installed:
  • IBM® DB2® Enterprise Server Edition, version 9.5 FixPak 1
  1. Log in to the DB2 server as a database administrator.
  2. Create a directory that has write and execute permission, for example DB_dir.
  3. Copy the installation .tar file, IBMPresenceServerDbPackage_7.0.tar, from the installation medium to the new directory.
  4. Switch to the new directory.
  5. Unpack the installation .tar file using the following command:
    tar -xvf IBMPresenceServerDbPackage_7.0.tar
  6. Switch to the following directory: was_root/installableApps/presence/scripts/dbScripts/presence.
  7. Verify that the following files exist in /presence:
    • ConfigDB2.sh
    • RunConfigDB2.sh
    • CreateDB2Tables.ddl
  8. Run the following commands to ensure that the database configuration scripts will run properly:
    • chmod 755 ConfigDB2.sh
    • chmod 755 RunConfigDB2.sh
  9. Edit the database preparation script, RunConfigDB2.sh, for your environment:
    1. Open RunConfigDB2.sh using a text editor.
    2. Locate the line that begins with the following text:
      • #Update command line parameters here.
    3. Update values for each parameter listed.
      Parameter Description Default value
      DBSERVER Fully qualified name of the database server
      • Linux Should match the Linux hostname command value if you are running the script directly on the database server
      <hostname>
      DBPORT Number for the listening port on the database server 50000
      DBNAME Name of the database PSDB
      DBALIAS Alias by which the database is known PSDB
      DBLOCALE Territory code that identifies your DB2 locale, for example US or JP US
      DBINSTANCE Name of the database instance db2inst
      DBINSTANCPW Password for the database instance <pw>
      DBUSER User ID for the authorized user (the ID with which you are logged in) db2inst
      DBUSERPW Password for the authorized user <pw>
      DBDIR Directory in which the database files are to be created (should be a directory with write permission) /home/db2inst
      DBCREATE Boolean value specifying whether the database should be recreated TRUE
      For example:
      DBSERVER=dbserver.example.com
      DBPORT=50000
      DBNAME=PSDB
      DBALIAS=PSDB
      DBLOCALE=US
      DBINSTANCE=db2inst
      DBINSTANCPW=inst_pw
      DBUSER=db2inst
      DBUSERPW=user_pw
      DBDIR=/home/db2inst
      DBCREATE=TRUE
    4. Run the script.
  10. Verify that the database was created properly by typing the following command, where database_alias is the alias you identified in the RunConfigDB2.sh script:
    • db2 connect to database_alias user database_administrator_ID
    For example:
    db2 connect to PSDB user db2inst
    If the script ran properly, the following results display:
    Database Connection Information
    
     Database server        = DB2/LINUX 9.5.1
     SQL authorization ID   = database_administrator_ID
     Local database alias   = database_alias
Results
Note: If errors occur when you run the database preparation script, refer to the topic Troubleshooting the database script.
What to do next
The required DB2 database tables will be created for you when you run the Presence Server interactive installation or silent installation.



Terms of use
(C) Copyright IBM Corporation 2009. All Rights Reserved.