This example was developed using DB2 Express-C 9.7 for Linux (Ubuntu). If you were using a different version you would need to adapt some commands to your environment.
If you did not yet installed the software provided by IBM, please refer to the official IBM site to download the software and to pick-up the information necessary to install and configure the database. This manual does not give you information related to IBM DB2 technology: it is assumed you already installed and configured the database.
The LIXA software must be configured to support the IBM DB2 server resource manager as explained in the section called “Linking third party resource managers”.
If your server didn't start-up automatically at boot time, you could start it with the following commands:
tiian@ubuntu:~$ ps -ef | grep db2 | grep -v grep tiian@ubuntu:~$ sudo /etc/init.d/db2exc start * Starting DAS: done. * Instance db2inst1 ( db2c_db2inst1 ): done. * Activating database SAMPLE done. tiian@ubuntu:~$ ps -ef | grep db2 | grep -v grep dasusr1 22959 1 0 10:54 pts/2 00:00:00 /home/dasusr1/das/adm/db2dasrrm root 23190 1 2 10:54 pts/2 00:00:00 db2wdog db2inst1 23192 23190 4 10:54 pts/2 00:00:01 db2sysc root 23193 23192 0 10:54 pts/2 00:00:00 db2ckpwd root 23194 23192 0 10:54 pts/2 00:00:00 db2ckpwd root 23195 23192 0 10:54 pts/2 00:00:00 db2ckpwd db2inst1 23206 23190 2 10:54 pts/2 00:00:00 db2acd ,0,0,0,1,0,0,0,1,0,8a6614,14,1e014,2,0,1,11fd0,0x12600000,0x12600000,1600000,740002,2,a0800d
Switch to user db2inst1
,
try to connect to database “SAMPLE”:
tiian@ubuntu:~$ sudo su - db2inst1 db2inst1@ubuntu:~$ db2 (c) Copyright IBM Corporation 1993,2007 Command Line Processor for DB2 Client 9.7.1 You can issue database manager commands and SQL statements from the command prompt. For example: db2 => connect to sample db2 => bind sample.bnd For general help, type: ?. For command help, type: ? command, where command can be the first few keywords of a database manager command. For example: ? CATALOG DATABASE for help on the CATALOG DATABASE command ? CATALOG for help on all of the CATALOG commands. To exit db2 interactive mode, type QUIT at the command prompt. Outside interactive mode, all commands must be prefixed with 'db2'. To list the current command option settings, type LIST COMMAND OPTIONS. For more detailed help, refer to the Online Reference Manual. db2 => connect to sample Database Connection Information Database server = DB2/LINUX 9.7.1 SQL authorization ID = DB2INST1 Local database alias = SAMPLE
Check the tables “ORG” and “DEPT” exist and contain some data:
db2 => select * from ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 8 record(s) selected. db2 => select * from DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - 14 record(s) selected.
OK, the “ORG” and “DEPT” tables are populated. If something went wrong, you should refer to IBM DB2 documentation to fix the issue before the next step because you would not be able to execute the sample program without a basic running installation.
We want to execute our example program with a generic user,
not just using db2inst1
because that's the system user dedicated to the database
instance execution. The commands below explain as the generic
user tiian
(my own
user) can be used instead of
db2inst1
.
Grant DBADM
privilege to the user
tiian
:
db2 => grant DBADM on database to user tiian DB20000I The SQL command completed successfully.
DBADM
is not the lowest authorization
level necessary to execute our example, but for the sake of
this example it's a “good enought” choice.
Add something like the 4 lines below to your
$HOME/.profile
or equivalent profile
configuration:
# The following three lines have been added by IBM DB2 instance utilities. if [ -f /home/db2inst1/sqllib/db2profile ]; then . /home/db2inst1/sqllib/db2profile fi
Then login again and check your environment:
tiian@ubuntu:~$ env|grep -i db2 DB2INSTANCE=db2inst1 LD_LIBRARY_PATH=/home/db2inst1/sqllib/lib32 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/db2inst1/sqllib/bin:/home/db2inst1/sqllib/adm:/home/db2inst1/sqllib/misc:/home/db2inst1/sqllib/db2tss/bin CLASSPATH=/home/db2inst1/sqllib/java/db2java.zip:/home/db2inst1/sqllib/java/db2jcc.jar:/home/db2inst1/sqllib/java/sqlj.zip:/home/db2inst1/sqllib/function:/home/db2inst1/sqllib/java/db2jcc_license_cu.jar:.
As shown above,
DB2INSTANCE
, LD_LIBRARY_PATH
,
PATH
variables should refer to DB2 stuff too.
Connect to the database using your own user instead of
db2inst1
:
tiian@ubuntu:~$ db2 (c) Copyright IBM Corporation 1993,2007 Command Line Processor for DB2 Client 9.7.1 You can issue database manager commands and SQL statements from the command prompt. For example: db2 => connect to sample db2 => bind sample.bnd For general help, type: ?. For command help, type: ? command, where command can be the first few keywords of a database manager command. For example: ? CATALOG DATABASE for help on the CATALOG DATABASE command ? CATALOG for help on all of the CATALOG commands. To exit db2 interactive mode, type QUIT at the command prompt. Outside interactive mode, all commands must be prefixed with 'db2'. To list the current command option settings, type LIST COMMAND OPTIONS. For more detailed help, refer to the Online Reference Manual. db2 => connect to sample Database Connection Information Database server = DB2/LINUX 9.7.1 SQL authorization ID = TIIAN Local database alias = SAMPLE db2 => select * from DB2INST1.ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 8 record(s) selected. db2 => select * from DB2INST1.DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - 14 record(s) selected. db2 => quit DB20000I The QUIT command completed successfully.
You have just verified that a generic user, like
tiian
in the example above, can connect to the database and execute
some query.
Start the state server as shown below:
tiian@ubuntu:~$ sudo su - lixa lixa@ubuntu:~$ /opt/lixa/sbin/lixad --daemon lixa@ubuntu:~$ exit logout tiian@ubuntu:~$ ps -ef|grep lixad|grep -v grep lixa 12866 1 0 21:35 ? 00:00:00 /opt/lixa/sbin/lixad --daemon
Prepare the client (Application Program) using the below commands (gcc command was splitted on several lines using \ to help readability, but you may use a single line):
tiian@ubuntu:~$ mkdir tmp tiian@ubuntu:~$ cd tmp tiian@ubuntu:~/tmp$ cp /opt/lixa/share/doc/lixa-X.Y.Z/examples/example3_db2.c . tiian@ubuntu:~/tmp$ gcc example3_db2.c $(/opt/lixa/bin/lixa-config -c -f -l -d) \ > -I/opt/ibm/db2/V9.7/include -L/opt/ibm/db2/V9.7/lib32/ -ldb2 -o example3_db2
Verify the executable produced by gcc:
tiian@ubuntu:~/tmp$ ldd example3_db2 linux-gate.so.1 => (0xb775f000) liblixac.so.0 => /opt/lixa/lib/liblixac.so.0 (0xb7744000) libdb2.so.1 => /home/db2inst1/sqllib/lib32/libdb2.so.1 (0xb6212000) libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb60b4000) libgmodule-2.0.so.0 => /usr/lib/libgmodule-2.0.so.0 (0xb60b0000) libdl.so.2 => /lib/tls/i686/cmov/libdl.so.2 (0xb60ac000) libgthread-2.0.so.0 => /usr/lib/libgthread-2.0.so.0 (0xb60a7000) librt.so.1 => /lib/tls/i686/cmov/librt.so.1 (0xb609e000) libglib-2.0.so.0 => /usr/lib/libglib-2.0.so.0 (0xb5fed000) libxml2.so.2 => /usr/lib/libxml2.so.2 (0xb5ecc000) liblixab.so.0 => /opt/lixa/lib/liblixab.so.0 (0xb5eb9000) libpthread.so.0 => /lib/tls/i686/cmov/libpthread.so.0 (0xb5ea1000) libcrypt.so.1 => /lib/tls/i686/cmov/libcrypt.so.1 (0xb5e6e000) libpam.so.0 => /lib/libpam.so.0 (0xb5e64000) libm.so.6 => /lib/tls/i686/cmov/libm.so.6 (0xb5e3f000) libdb2dascmn.so.1 => /home/db2inst1/sqllib/lib32/libdb2dascmn.so.1 (0xb5e12000) libdb2g11n.so.1 => /home/db2inst1/sqllib/lib32/libdb2g11n.so.1 (0xb57a4000) libdb2genreg.so.1 => /home/db2inst1/sqllib/lib32/libdb2genreg.so.1 (0xb5763000) libdb2install.so.1 => /home/db2inst1/sqllib/lib32/libdb2install.so.1 (0xb5758000) libdb2locale.so.1 => /home/db2inst1/sqllib/lib32/libdb2locale.so.1 (0xb5745000) libdb2osse.so.1 => /home/db2inst1/sqllib/lib32/libdb2osse.so.1 (0xb5440000) libdb2osse_db2.so.1 => /home/db2inst1/sqllib/lib32/libdb2osse_db2.so.1 (0xb53d0000) libdb2trcapi.so.1 => /home/db2inst1/sqllib/lib32/libdb2trcapi.so.1 (0xb53bc000) libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0xb52c9000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xb52be000) /lib/ld-linux.so.2 (0xb7760000) libpcre.so.3 => /usr/lib/libpcre.so.3 (0xb5297000) libz.so.1 => /usr/lib/libz.so.1 (0xb5282000) libuuid.so.1 => /lib/libuuid.so.1 (0xb527d000)
Set-up the LIXA_PROFILE
environment variable:
tiian@ubuntu:~/tmp$ echo $LIXA_PROFILE tiian@ubuntu:~/tmp$ export LIXA_PROFILE=DB2_DYN tiian@ubuntu:~/tmp$ echo $LIXA_PROFILE DB2_DYN
No additional DB2 variables are needed because they are automatically set at login (see the section called “Set-up DB2 environment”).
We set LIXA_PROFILE
to value
“DB2_DYN”, looking at
/opt/lixa/etc/lixac_conf.xml
:
<profile name="DB2_DYN"> <sttsrvs> <sttsrv>local_1</sttsrv> </sttsrvs> <rsrmgrs> <rsrmgr>IBMDB2_dynreg</rsrmgr> </rsrmgrs> </profile>
the profile references the Resource Manager named “IBMDB2_dynreg”, looking again at the config file:
<rsrmgr name="IBMDB2_dynreg" switch_file="/opt/lixa/lib/switch_ibmdb2_dynreg.so" xa_open_info="axlib=/opt/lixa/lib/liblixac.so,db=sample,tpm=lixa" xa_close_info="" />
we can discover how the DB2 database is configured for XA [22].
It is suggested to open two different terminals: the first one
connected to “SAMPLE” DB2 database and the second
one pointing to the directory where the compiled program
example3_db2
lives.
First teminal session:
tiian@ubuntu:~$ db2 (c) Copyright IBM Corporation 1993,2007 Command Line Processor for DB2 Client 9.7.1 You can issue database manager commands and SQL statements from the command prompt. For example: db2 => connect to sample db2 => bind sample.bnd For general help, type: ?. For command help, type: ? command, where command can be the first few keywords of a database manager command. For example: ? CATALOG DATABASE for help on the CATALOG DATABASE command ? CATALOG for help on all of the CATALOG commands. To exit db2 interactive mode, type QUIT at the command prompt. Outside interactive mode, all commands must be prefixed with 'db2'. To list the current command option settings, type LIST COMMAND OPTIONS. For more detailed help, refer to the Online Reference Manual. db2 => connect to SAMPLE Database Connection Information Database server = DB2/LINUX 9.7.1 SQL authorization ID = TIIAN Local database alias = SAMPLE
Second teminal session:
tiian@ubuntu:~/tmp$ ls -la total 28 drwxr-xr-x 2 tiian tiian 4096 2011-04-22 16:26 . drwxr-xr-x 40 tiian tiian 4096 2011-04-18 22:55 .. -rwxr-xr-x 1 tiian tiian 11030 2011-04-22 16:26 example3_db2 -rw-r--r-- 1 tiian tiian 5898 2011-04-22 16:23 example3_db2.c
Check the content of “DB2INST1.ORG” table before program execution:
db2 => select * from DB2INST1.ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 8 record(s) selected.
Execute the program:
tiian@ubuntu:~/tmp$ ./example3_db2 insert org
Check the content of the table again:
db2 => select * from DB2INST1.ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 150 Europe 231 R&D Mojan 9 record(s) selected.
The example program inserted the last row! You can execute it again
tiian@ubuntu:~/tmp$ ./example3_db2 insert org
and it inserts another row:
db2 => select * from DB2INST1.ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 150 Europe 231 R&D Mojan 150 Europe 231 R&D Mojan 10 record(s) selected.
Because there is no an unique constraint on this table; if you want to check an error while inserting, use “DEPT” table instead.
db2 => select * from DB2INST1.DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - 14 record(s) selected.
Try to insert the same row twice:
tiian@ubuntu:~/tmp$ ./example3_db2 insert dept tiian@ubuntu:~/tmp$ ./example3_db2 insert dept Unable to execute the SQL statement ('INSERT INTO DB2INST1.DEPT (DEPTNO, DEPTNAME, ADMRDEPT) VALUES('Z99', 'RESEARCH & DEVELOPMENT', 'E01')'): -1
Check the table content:
db2 => select * from DB2INST1.DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - Z99 RESEARCH & DEVELOPMENT - E01 - 15 record(s) selected.
Only one record was inserted. As a final step, clean up both the tables:
tiian@ubuntu:~/tmp$ ./example3_db2 delete dept tiian@ubuntu:~/tmp$ ./example3_db2 delete org
and check the tables were cleaned-up:
db2 => select * from DB2INST1.DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - 14 record(s) selected. db2 => select * from DB2INST1.ORG DEPTNUMB DEPTNAME MANAGER DIVISION LOCATION -------- -------------- ------- ---------- ------------- 10 Head Office 160 Corporate New York 15 New England 50 Eastern Boston 20 Mid Atlantic 10 Eastern Washington 38 South Atlantic 30 Eastern Atlanta 42 Great Lakes 100 Midwest Chicago 51 Plains 140 Midwest Dallas 66 Pacific 270 Western San Francisco 84 Mountain 290 Western Denver 8 record(s) selected.
To verify the LIXA Transaction Manager and DB2 Resource Manager are using the dynamic transaction registration, you can inspect the trace produced by the LIXA client library:
tiian@ubuntu:~/tmp$ export LIXA_TRACE_MASK=0x00002000 tiian@ubuntu:~/tmp$ echo $LIXA_TRACE_MASK 0x00002000 tiian@ubuntu:~/tmp$ ./example3_db2 insert dept 2>&1 | grep ax_reg 2011-04-22 22:08:40.650458 [6654/3039381232] ax_reg: rmid=0, xid=0xbfcd65d0, flags=0x0 2011-04-22 22:08:40.650858 [6654/3039381232] ax_reg: the application program has started a transaction (TX states S3); this XID '1279875137.9a73b024b7ab4018915b54761d3dcd79.e41205820a9c722218578c0eeec6a27c' will be returned 2011-04-22 22:08:40.651156 [6654/3039381232] ax_reg: sending 153 bytes to the server for step 8 2011-04-22 22:08:40.651316 [6654/3039381232] ax_reg/excp=7/ret_cod=0/errno=2
I don't know how you can retrieve the same information on the DB2 side, but there probably is a way to do it. Clean-up again the table...
tiian@ubuntu:~/tmp$ ./example3_db2 delete dept
If you desire static transaction registration instead of the
dynamic one, you can switch the LIXA_PROFILE
:
tiian@ubuntu:~/tmp$ export LIXA_PROFILE=DB2_STA tiian@ubuntu:~/tmp$ echo $LIXA_PROFILE DB2_STA tiian@ubuntu:~/tmp$ export LIXA_TRACE_MASK=0x00002000 tiian@ubuntu:~/tmp$ echo $LIXA_TRACE_MASK 0x00002000
you can verify in file
/opt/lixa/etc/lixac_conf.xml
that “DB2_STA” is associated to static registration.
Execute the program:
tiian@ubuntu:~/tmp$ ./example3_db2 insert dept 2>&1 | grep xa_start 2011-04-22 22:19:45.717003 [6745/3038836464] lixa_xa_start [...] 2011-04-22 22:19:45.758075 [6745/3038836464] lixa_xa_start: xa_start_entry(xid, 0, 0x0) = 0 2011-04-22 22:19:45.758321 [6745/3038836464] lixa_xa_start: sending 210 bytes to the server for step 24 2011-04-22 22:19:45.758681 [6745/3038836464] lixa_xa_start/excp=10/ret_cod=0/errno=2
Check the content of the table:
db2 => select * from DB2INST1.DEPT DEPTNO DEPTNAME MGRNO ADMRDEPT LOCATION ------ ------------------------------------ ------ -------- ---------------- A00 SPIFFY COMPUTER SERVICE DIV. 000010 A00 - B01 PLANNING 000020 A00 - C01 INFORMATION CENTER 000030 A00 - D01 DEVELOPMENT CENTER - A00 - D11 MANUFACTURING SYSTEMS 000060 D01 - D21 ADMINISTRATION SYSTEMS 000070 D01 - E01 SUPPORT SERVICES 000050 A00 - E11 OPERATIONS 000090 E01 - E21 SOFTWARE SUPPORT 000100 E01 - F22 BRANCH OFFICE F2 - E01 - G22 BRANCH OFFICE G2 - E01 - H22 BRANCH OFFICE H2 - E01 - I22 BRANCH OFFICE I2 - E01 - J22 BRANCH OFFICE J2 - E01 - Z99 RESEARCH & DEVELOPMENT - E01 - 15 record(s) selected.
And clean the table again:
tiian@ubuntu:~/tmp$ unset LIXA_TRACE_MASK tiian@ubuntu:~/tmp$ ./example3_db2 delete dept
[22]
The content of xa_open_info
string is
documented at IBM Infocenter: search the string
“xa_open string formats” in the documentation
relevant to your installed version; this is a link
http://publib.boulder.ibm.com/infocenter/db2luw/v9r7/topic/com.ibm.db2.luw.admin.2pc.doc/doc/r0005080.html
but it may change in the future.