Setup Websphere MQ File Transfer Database Logger

Step 1. Run the following db2 command:

— drop if necessary and then create FTELOGDB

echo *******************************************************

echo the following command may fail because the database did

echo NOT previously exist, this is an acceptable error

echo *******************************************************

drop database FTELOGDB

echo — Creating database FTELOGDB

create database FTELOGDB

echo — Connect to FTELOGDB database

connect to FTELOGDB user esbuser using wesb4soa

— catalog FTELOGDB as a odbc data source

catalog system odbc data source FTELOGDB

list system odbc data sources

echo — now create the schemae, tables and views

echo — use this db2cmd command console

echo — it is already connected to the database

Step 2: Create the DB2 Schema Tables

Navigate to: C:\Program Files\IBM\WMQFTE\tools\sql

Execute the following command:

db2 –v -t –f ftelog_tables_db2.sql

Step 3: Configure the Database Logger Properties File

Navigate to: *\WMQFTE\config

Open file in Notepad: databaselogger.properties

Edit the following values:

wmqfte.queue.manager=QM_COORD1

(Coordinator Queue Manager Name)

wmqfte.database.name=FTELOGDB

(Database Name created in Step 1)

wmqfte.database.driver=D:/Applications/IBM/SQLLIB/java/db2jcc.jar;D:/Applications/IBM/SQLLIB/java/db2jcc_license_cu.jar

(DB2 Driver Path)

wmqfte.database.native.library.path=C:/Applications/IBM/SQLLIB/lib

(Library Path to DB2)

Step 4: Setup the transaction manager

Open MQ Explorer right click on the Coordinator Queue Manager and select Properties. Under XA Resource Manager click the ‘Add’ button.

Enter FTELOGDB as the Name.

Enter jdbcdb2.dll as the SwitchFile.

Enter db=FTELOGDB,uid=db2admin,pwd=db8admin,toc=p,tpm=mq as the XAOpenString.

Make sure the ThreadOfControl is set to Process.

Press the OK button to add the XA resource manager to the queue manager.

Click OK

Step 5: Copy the jdbcdb2.jar to the existing folder

Navigate to *\IBM\WebSphere MQ

execute the following command to copy the jdbcdb2.jar file: copy java\lib\jdbc\jdbcdb2.dll exits

Step 6: Execute a Controlled Stop of the Coordinator Queue Manager

Step 7: Start the Database Logger

Execute the following command in *\MQFTE\tools\bin: fteStartDatabaseLogger –F


Step 8: Run a new Transfer

Navigate to ‘Manage File Transfer’ and connect the Coordinator Queue Manager and right click on Transfer Log and select ‘New Transfer’

Select a Agent, file to transfer and Click Next till you see the following window:

Add two metadata attribute value pairs:

Click Next and Finish to start file transfer

Step 9: Open DB2 Control Panel to View the Database Logger Table

Navigate to your Database Logger Database -> Views -> Basic_Transfer_Details.

Navigate to your Database Logger Database -> Tables -> Metadata.

Optional Stop Database Logger:

Navigate to *\MQFTE\tools\bin\fteStopDatabaseLogger.cmd

Database Logger will stop succesfully else see result of error.

1 Comment

  1. Hatcher Jeter says:

    Very nice article. Much clearing the the doc.
    Thank you

Leave a Comment