Create the DB2® usage
record database.
Before you begin
Before you begin, you must have completed
the following task:
- Installed and started IBM® DB2 Enterprise
Server Edition, 9.5 FixPak 1
- Installed the DB2 client or copied the DB2 client files to all
WebSphere servers
About this task
Complete the following steps on the database
server where you want to create the database. The following instructions
use the interactive menu. You can run the script as a single command.
Additional information about using the single command is provided
in the script.
- Log in to the DB2 server
as a database administrator.
- Create a directory that has write and execute permission,
for example DB_dir.
- Copy the installation .tar file, IBMXdmsDbPackage_7.0.0.tar,
from the installation medium to the new directory.
- Switch to the new directory.
- Unpack the installation .tar file using the following command:
tar -xvf IBMXdmsDbPackage_7.0.0.tar
- Switch to the following directory: DB_dir/usageRecords.
- Run the crtSrvDb2.sh script using the command: ./crtsrvDb2.sh dbServer dbPort dbLocal dbNodeName dbName dbAlias dbLocale dbAdmin dbAdminPW dbUser dbUserPW INITorDDLFile infoflag,
for example:
./crtsrvDb2.sh dh_hostname 50000 TRUE RDBSRV XDMSURDB XDMSUR US db2inst1 password db2inst1 password UsageDbDb2.ddl TRUE
Note: This
command must be run twice. Once with the INITorDDLFile set to INIT
and a second time with the same parameters set to UsageDbDb2.ddl.
The
following table provides the parameter information for the command:
Parameter |
Description |
Example value |
dbServer |
Database server hostname |
Fully qualified host name |
dbPort |
Database server connection port |
50000 |
dbLocal |
Local database |
TRUE for local |
dbNodeName |
Remote database server node name |
RDBSRV |
dbName |
Database name |
XDMSURDB |
dbAlias |
Database alias name |
XDMSUR |
dbLocale |
Database territory code |
US |
dbAdmin |
Database server administrator instance ID |
db2inst1 |
dbAdminPW |
Database server administrator instance password |
pw |
dbUser |
Database user ID |
db2inst1 |
dbUserPW |
Database user password |
pw |
INITorDDLFile |
'INIT' to initialize or the path to DDL file |
UsageDbDb2.ddl |
infoflag |
Display information flag |
TRUE |
- Verify the configuration tables were created properly.
- Verify the tables were created properly:
- Connect to the database using the following DB2 command:
db2 connect to XDMSUR user user_name using password
- Verify the tables were created using the following DB2 command:
db2 list tables for schema user_name
For example, if the user name is db2admin, use the db2
list tables for schema db2admin command. The
following tables should be listed: