Configuring global coordination with Oracle using a 32-bit queue manager

Configure your broker environment to globally coordinate message flow transactions with updates in Oracle databases under the control of a 32-bit queue manager.

Before you start:
Complete this task to configure the broker environment when the broker uses a 32-bit queue manager.

All WebSphere® MQ Version 5.3 queue managers and all WebSphere MQ Version 6 queue managers on 32-bit platforms run in 32-bit mode. 32-bit queue managers can coordinate transactions only in 32-bit mode and can coordinate message flows that are deployed only to 32-bit execution groups.

To configure your broker environment for global coordination using a 32-bit queue manager as the transaction manager:

  1. Linux platformUNIX platform On Linux® on x86 and UNIX® only, create the following symbolic links to specify the location of the ODBC database drivers that are supplied with WebSphere Message Broker.

    You must enter these commands on a single line; line breaks have been added to improve readability.

    AIX platform Start of changeOn AIX®:End of change
    ln -s install_dir/merant/lib/libUKicu20.a 
       /var/mqm/exits/libUKicu20.a
    ln -s Oracle_install_dir/lib32/libclntsh.a 
       /var/mqm/exits/libclntsh.a
    ln -s Oracle_install_dir/lib32/libclntsh.a 
       /usr/lib/libclntsh.a
    HP-UX platform On HP-UX on PA-RISC:
    ln -s install_dir/merant/lib/libUKicu20.sl 
       /var/mqm/exits/libUKicu20.sl
    ln -s Oracle_install_dir/lib32/libclntsh.sl 
       /var/mqm/exits/libclntsh.sl
    ln -s Oracle_install_dir/lib32/libclntsh.sl 
       /usr/lib/libclntsh.sl
    Linux platformSolaris platform On Linux on x86 and Solaris on SPARC:
    ln -s install_dir/merant/lib/libUKicu20.so 
       /var/mqm/exits/libUKicu20.so
    ln -s Oracle_install_dir/lib32/libclntsh.so 
       /var/mqm/exits/libclntsh.so
    ln -s Oracle_install_dir/lib32/libclntsh.so 
       /usr/lib/libclntsh.so
    Where:
    • install_dir is the location in which WebSphere Message Broker is installed.
    • Oracle_install_dir is the location in which Oracle is installed, which is the same value as $ORACLE_HOME.
  2. Configure the broker's queue manager with XA resource manager information for each database that is involved in the transaction that the queue manager will globally coordinate. If the message flows reference message dictionaries, or contain Publication nodes, you must use the same method to define XA resource manager information for the broker database and for the user databases.

    Linux platformUNIX platform Start of changeOn Linux on x86 and UNIX:End of change

    1. Open the queue manager's qm.ini file in a text editor. The qm.ini file is located at /var/mqm/qmgrs/queue_manager_name/qm.ini, where queue_manager_name is the name of the broker that is associated with the queue manager.
    2. At the end of the qm.ini file, paste the following stanza:
      XAResourceManager:
      Name=OracleXA
      SwitchFile=SwitchFilePath 
      XAOpenString=ORACLE_XA+SQLNET=MyServerName
         +HostName=MyHostName
         +PortNumber=MyPortNumber
         +Sid=MySID
         +ACC=P/MyUserId/MyPassword
         +sestm=100+threads=TRUE
         +DataSource=MyDataSourceName
         +DB=MyDataSourceName+K=2+
      XACloseString=
      ThreadOfControl=THREAD
    3. On the SwitchFile line of the stanza, replace SwitchFilePath with the full path to the switch file for your operating system. The following table shows the file path of the switch file for each operating system, where install_dir is the location in which the broker is installed.
      Operating system Switch file path
      HP-UX on PA-RISC install_dir/merant/lib/UKor8dtc20.sl
      All other platforms install_dir/merant/lib/UKor8dtc20.so

      The switch file is supplied by WebSphere Message Broker.

    4. On the XAOpenString line, replace the following values with values that are appropriate for your configuration:
      • MyServerName is the name of the Oracle Server.
      • MyHostName is the name of the TCP/IP host that hosts the Oracle database.
      • MyPortNumber is the TCP/IP port on which the Oracle database is listening.
      • MySID is the Oracle System Identifier (SID) of the database.
      • MyUserId must be the user name that the broker uses to connect to the database. The user name that the broker uses can be defined in a number of ways. If you use the -u parameter on the mqsicreatebroker command when you create the broker, this user name is used to connect to the database, unless the mqsisetdbparms command has been used to associate a specific user name and password with a specific data source name (DSN). If you use neither the -u parameter on the mqsicreatebroker command, nor the mqsisetdbparms command, the name used is the broker's service user name, which you define with the -i parameter on the mqsicreatebroker command.
      • MyPassword is the password that is associated with the user name.
      • MyDataSourceName is the ODBC data source name for the database.
    5. Accept the default values for all the other lines in the stanza. For example, on AIX:
      XAResourceManager:
      Name=OracleXA
      SwitchFile=/opt/mqsi/merant/lib/UKor8dtc20.so
      XAOpenString=ORACLE_XA+SQLNET=diaz
         +HostName=diaz.hursley.ibm.com
         +PortNumber=1521+Sid=diaz
         +ACC=P/wbrkuid/wbrkpw
         +sestm=100+threads=TRUE
         +DataSource=MYDB+DB=MYDB+K=2+
      XACloseString=
      ThreadOfControl=THREAD

    Windows platform On Windows®:

    1. From the Start menu, open the graphical administration tool for your version of WebSphere MQ:
      • WebSphere MQ Version 5.3: WebSphere MQ Services
      • WebSphere MQ Version 6: WebSphere MQ Explorer
    2. Open the queue manager's Properties dialog box, then open the Resources (Version 5.3) or XA resource managers (Version 6) page.
    3. In the SwitchFile field, enter the full path to the switch file, as shown in the following example where install_dir is the location in which the broker is installed:
      install_dir\bin\UKor8dtc20.dll
    4. In the XAOpenString field, paste the following string:
      ORACLE_XA+SQLNET=MyServerName
         +HostName=MyHostName
         +PortNumber=MyPortNumber
         +Sid=MySID
         +ACC=P/MyUserId/MyPassword+sestm=100+threads=TRUE
         +DataSource=MyDataSourceName
         +DB=MyDataSourceName+K=2+
    5. In the XAOpenString field, replace the values with values that are appropriate for your configuration:
      • MyServerName is the name of the Oracle Server.
      • MyHostName is the name of the TCP/IP host that hosts the Oracle database.
      • MyPortNumber is the TCP/IP port on which the Oracle database is listening.
      • MySID is the Oracle System Identifier (SID) of the database.
      • MyUserId must be the user name that the broker uses to connect to the database. The user name that the broker uses can be defined in a number of ways. If you use the -u parameter on the mqsicreatebroker command when you create the broker, this user name is used to connect to the database, unless the mqsisetdbparms command has been used to associate a specific user name and password with a specific data source name (DSN). If you use neither the -u parameter on the mqsicreatebroker command, nor the mqsisetdbparms command, the name used is the broker's service user name, which you define with the -i parameter on the mqsicreatebroker command.
      • MyPassword is the password that is associated with the user name.
      • MyDataSourceName is the ODBC data source name for the database.
      For example:
      ORACLE_XA+SQLNET=diaz
         +HostName=diaz.hursley.ibm.com
         +PortNumber=1521+Sid=diaz
         +ACC=P/wbrkuid/wbrkpw
         +sestm=100+threads=TRUE
         +DataSource=MYDB+DB=MYDB+K=2+
    6. Accept the default values for all the other fields on the page.
  3. Stop then restart the queue manager to apply the changes, because qm.ini is read only while the queue manager is running.
    To stop then restart the queue manager, enter the following commands, where queue_manager_name is the name of the queue manager:
    endmqm queue_manager_name
    strmqm queue_manager_name

    When the queue manager restarts, check the queue manager's log for any warnings that are associated with the restart. The log files are located in /var/mqm/qmgrs/queue_manager_name/errors, where queue_manager_name is the name of the queue manager that you restarted.

    When the queue manager restarts successfully, the changes that you made to qm.ini are applied.
Oracle is now configured for global coordination with a 32-bit queue manager coordinating transactions.
Next: you can deploy globally coordinated message flows to the broker.
Related tasks
Configuring globally coordinated message flows
Configuring global coordination of transactions (two-phase commit)
Related reference
Supported databases
mqsicreatebroker command
mqsisetdbparms command
Related information
WebSphere MQ Version 6 information center online
WebSphere MQ library Web page
Notices | Trademarks | Downloads | Library | Support | Feedback

Copyright IBM Corporation 1999, 2009Copyright IBM Corporation 1999, 2009.
Last updated : 2009-01-07 15:19:58

ac00910_