Debian Codegraph @

docs/programmer_reference/xa_xa_config.html

raw symbols SCIP
1 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml">
4 <head>
5 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
6 <title>Configuring Berkeley DB with the Tuxedo System</title>
7 <link rel="stylesheet" href="gettingStarted.css" type="text/css" />
8 <meta name="generator" content="DocBook XSL Stylesheets V1.73.2" />
9 <link rel="start" href="index.html" title="Berkeley DB Programmer's Reference Guide" />
10 <link rel="up" href="xa.html" title="Chapter 13.  Distributed Transactions" />
11 <link rel="prev" href="xa_xa_intro.html" title="XA Introduction" />
12 <link rel="next" href="xa_xa_restrict.html" title="Restrictions on XA Transactions" />
13 </head>
14 <body>
15 <div xmlns="" class="navheader">
16 <div class="libver">
17 <p>Library Version 11.2.5.3</p>
18 </div>
19 <table width="100%" summary="Navigation header">
20 <tr>
21 <th colspan="3" align="center">Configuring Berkeley DB with the Tuxedo System</th>
22 </tr>
23 <tr>
24 <td width="20%" align="left"><a accesskey="p" href="xa_xa_intro.html">Prev</a> </td>
25 <th width="60%" align="center">Chapter 13. 
26 Distributed Transactions
27 </th>
28 <td width="20%" align="right"> <a accesskey="n" href="xa_xa_restrict.html">Next</a></td>
29 </tr>
30 </table>
31 <hr />
32 </div>
33 <div class="sect1" lang="en" xml:lang="en">
34 <div class="titlepage">
35 <div>
36 <div>
37 <h2 class="title" style="clear: both"><a id="xa_xa_config"></a>Configuring Berkeley DB with the Tuxedo System</h2>
38 </div>
39 </div>
40 </div>
41 <div class="toc">
42 <dl>
43 <dt>
44 <span class="sect2">
45 <a href="xa_xa_config.html#idp52786896">Update the Resource Manager File in Tuxedo</a>
46 </span>
47 </dt>
48 <dt>
49 <span class="sect2">
50 <a href="xa_xa_config.html#idp52812512">Build the Transaction Manager Server</a>
51 </span>
52 </dt>
53 <dt>
54 <span class="sect2">
55 <a href="xa_xa_config.html#idp52759288">Update the UBBCONFIG File</a>
56 </span>
57 </dt>
58 </dl>
59 </div>
60 <p>
61 To configure the Tuxedo system to use Berkeley DB resource managers, do the following:
62 </p>
63 <div class="sect2" lang="en" xml:lang="en"><div class="titlepage"><div><div><h3 class="title"><a id="idp52786896"></a>Update the Resource Manager File in Tuxedo</h3></div></div></div><p>For the purposes of this discussion, assume that the Tuxedo home directory is in</p><pre class="programlisting">/home/tuxedo</pre>
64 In that case, the resource manager file will be located in
65 <pre class="programlisting">/home/tuxedo/udataobj/RM</pre>
66 Edit the resource manager file to identify the Berkeley DB resource manager, the name of the resource manager switch, and the name of the library for the resource manager.
67 <p>For example, on a RedHat Linux Enterprise (64-bit) installation of Oracle Tuxedo 11gR1, you can update the resource manager file by adding the following line:</p><pre class="programlisting">BERKELEY-DB:db_xa_switch:-L${DB_INSTALL}/lib -ldb </pre><p>where <code class="literal">${DB_INSTALL}</code> is the directory into which you installed the Berkeley DB
68 library.</p><p>Note that the load options may differ depending on the platform of
69 your system.</p></div>
70 <div class="sect2" lang="en" xml:lang="en">
71 <div class="titlepage">
72 <div>
73 <div>
74 <h3 class="title"><a id="idp52812512"></a>Build the Transaction Manager Server</h3>
75 </div>
76 </div>
77 </div>
78 <p>To do this, use the
79 Tuxedo <span class="bold"><strong>buildtms(1)</strong></span> utility. The <span class="bold"><strong>buildtms</strong></span> command will create
80 the <code class="literal">Berkeley-DB</code> resource manager in the directory from which it was run.
81 The parameters to the <span class="bold"><strong>buildtms</strong></span> command should be:</p>
82 <pre class="programlisting">buildtms -v -o DBRM -r BERKELEY-DB</pre>
83 <p>This will create an executable transaction manager server, <code class="literal">DBRM</code>, which is
84 called by Tuxedo to process begins, commits, and aborts.</p>
85 </div>
86 <div class="sect2" lang="en" xml:lang="en">
87 <div class="titlepage">
88 <div>
89 <div>
90 <h3 class="title"><a id="idp52759288"></a>Update the UBBCONFIG File</h3>
91 </div>
92 </div>
93 </div>
94 <p>You must make sure that your TUXCONFIG environment variable
95 identifies an UBBCONFIG file that properly identifies your resource
96 managers. In the GROUPS section of the UBBCONFIG file, you should identify the
97 group's LMID and GRPNO, as well as the transaction manager server name
98 "TMSNAME=DBRM." You must also specify the OPENINFO parameter, setting it
99 equal to the string</p>
100 <pre class="programlisting">rm_name:dir</pre>
101 <p>where rm_name is the resource name specified in the RM file (that is,
102 BERKELEY-DB) and dir is the directory for the Berkeley DB home environment
103 (see <a href="../api_reference/C/envopen.html" class="olink">DB_ENV-&gt;open()</a> for a discussion of Berkeley DB environments).</p>
104 <p>Because Tuxedo resource manager startup accepts only a single string
105 for configuration, any environment customization that might have been
106 done via the config parameter to <a href="../api_reference/C/envopen.html" class="olink">DB_ENV-&gt;open()</a> must instead be done
107 by placing a <a class="xref" href="env_db_config.html" title="DB_CONFIG configuration file">DB_CONFIG configuration file</a> in the Berkeley DB environment directory.
108 See <a class="xref" href="env_naming.html" title="File naming">File naming</a> for further
109 information.</p>
110 <p>Consider the following configuration. We have built a transaction
111 manager server, as described previously. We want the Berkeley DB environment
112 to be <code class="literal">/home/dbhome</code>, our database files to be maintained in
113 <code class="literal">/home/datafiles</code>, our log files to be maintained in
114 <code class="literal">/home/log</code>, and we want a duplexed server.</p>
115 <p>The GROUPS section of the ubb file might look like the following:</p>
116 <pre class="programlisting">group_tm LMID=myname GRPNO=1 TMSNAME=DBRM TMSCOUNT=2 \
117 OPENINFO="BERKELEY-DB:/home/dbhome"</pre>
118 <p>There would be a <a class="xref" href="env_db_config.html" title="DB_CONFIG configuration file">DB_CONFIG configuration file</a> in the directory
119 <code class="literal">/home/dbhome</code> that contained the following two lines:</p>
120 <pre class="programlisting">set_data_dir /home/datafiles
121 set_lg_dir /home/log</pre>
122 <p>Finally, the UBBCONFIG file must be translated into a binary version using
123 Tuxedo's <span class="bold"><strong>tmloadcf</strong></span>(1) utility, and then the pathname of that
124 binary file must be specified as your TUXCONFIG environment variable.</p>
125 </div>
126 <p>At this point, your system is properly initialized to use the Berkeley DB
127 resource manager.</p>
128 <p>See <a href="../api_reference/C/db.html" class="olink">DB class</a> for further information on accessing data files
129 using XA.</p>
130 </div>
131 <div class="navfooter">
132 <hr />
133 <table width="100%" summary="Navigation footer">
134 <tr>
135 <td width="40%" align="left"><a accesskey="p" href="xa_xa_intro.html">Prev</a> </td>
136 <td width="20%" align="center">
137 <a accesskey="u" href="xa.html">Up</a>
138 </td>
139 <td width="40%" align="right"> <a accesskey="n" href="xa_xa_restrict.html">Next</a></td>
140 </tr>
141 <tr>
142 <td width="40%" align="left" valign="top">XA Introduction </td>
143 <td width="20%" align="center">
144 <a accesskey="h" href="index.html">Home</a>
145 </td>
146 <td width="40%" align="right" valign="top"> Restrictions on XA Transactions</td>
147 </tr>
148 </table>
149 </div>
150 </body>
151 </html>