Configuring Oracle
Oracle support and configuration information.
- Check environment variable settings.
- Create the Oracle switch load file.
- Add resource manager configuration information.
- Change the Oracle configuration parameters, if necessary.
Checking the Oracle environment variable settings
- ORACLE_HOME
- The Oracle home directory. For example, on UNIX and Linux® systems, use:
On Windows systems, use:export ORACLE_HOME=/opt/oracle/product/8.1.6
set ORACLE_HOME=c:\oracle\ora81
- ORACLE_SID
- The Oracle SID being used. If you are using Net8 for client/server connectivity, you might not
have to set this environment variable. Consult your Oracle documentation. The subsequent example is an example of setting this environment variable, on UNIX and Linux systems:
The equivalent on Windows systems is:export ORACLE_SID=sid1
set ORACLE_SID=sid1
If you run queue managers on Windows 64 bit systems, then only 64 bit Oracle clients must be installed. The switch load file, loaded by 64 bit queue managers, must access the Oracle 64 bit client libraries.
Creating the Oracle switch load file
C:\Program Files\IBM\WebSphere MQ\tools\c\samples\xatm
. To
create the Oracle switch load file with Microsoft Visual
C++, use: nmake /f xaswit.mak oraswit.dllThe generated switch file is placed in
. MQ_INSTALLATION_PATH
\exitsMQ_INSTALLATION_PATH
represents the high-level directory in which IBM MQ is installed.
You can find xaswit.mak in the directory
. MQ_INSTALLATION_PATH
/samp/xatmMQ_INSTALLATION_PATH
represents the high-level directory in which IBM MQ is installed.
make -f xaswit.mak oraswit
The contents of
MQ_INSTALLATION_PATH/samp/xatm are read-only when IBM MQ is installed, so to edit xaswit.mak,
copy all the files out of samp/xatm to another directory, modify
xaswit.mak, and then run make -f xaswit.makoraswit
from that
directory.The generated 32 bit switch load file is placed in /var/mqm/exits
.
The generated 64 bit switch load file is placed in /var/mqm/exits64
.
Adding resource manager configuration information for Oracle
- On Windows and Linux (x86 and x86-64 platforms) systems, use the MQ Explorer. Specify the details of the switch load file in the queue manager properties panel, under XA resource manager.
- On all other systems specify the details of the switch load file in the XAResourceManager stanza in the qm.ini file of the queue manager.
LogDir
to the XA open string so that all error and tracing information is logged to the same place.
- In Figure 1, the xa_open string has been used with four parameters. Additional parameters can be included as described in Oracle's documentation.
- When using the IBM MQ parameter
ThreadOfControl=THREAD
you must use the Oracle parameter+threads=true
in the XAResourceManager stanza.
See the Oracle8 Server Application Developer's Guide for more information about the xa_open string.
Changing Oracle configuration parameters
- Review your maximum sessions
- You might have to review your LICENSE_MAX_SESSIONS and PROCESSES settings to take into account the additional connections required by processes belonging to the queue manager. See Installing and configuring the database product for more details.
- Set database privileges
- The Oracle user name specified in the xa_open string must have privileges to access the DBA_PENDING_TRANSACTIONS view, as described in the Oracle documentation.
The necessary privilege can be given using the following example command:
grant select on DBA_PENDING_TRANSACTIONS to myuser;