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>Client to Client Transfer</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="Getting Started with Replicated Berkeley DB Applications" /> 10 <link rel="up" href="addfeatures.html" title="Chapter��5.��Additional Features" /> 11 <link rel="prev" href="noautoinit.html" title="Stop Auto-Initialization" /> 12 <link rel="next" href="bulk.html" title="Bulk Transfers" /> 13 </head> 14 <body> 15 <div class="navheader"> 16 <table width="100%" summary="Navigation header"> 17 <tr> 18 <th colspan="3" align="center">Client to Client Transfer</th> 19 </tr> 20 <tr> 21 <td width="20%" align="left"><a accesskey="p" href="noautoinit.html">Prev</a>��</td> 22 <th width="60%" align="center">Chapter��5.��Additional Features</th> 23 <td width="20%" align="right">��<a accesskey="n" href="bulk.html">Next</a></td> 24 </tr> 25 </table> 26 <hr /> 27 </div> 28 <div class="sect1" lang="en" xml:lang="en"> 29 <div class="titlepage"> 30 <div> 31 <div> 32 <h2 class="title" style="clear: both"><a id="c2ctransfer"></a>Client to Client Transfer</h2> 33 </div> 34 </div> 35 </div> 36 <div class="toc"> 37 <dl> 38 <dt> 39 <span class="sect2"> 40 <a href="c2ctransfer.html#fmwrkpeerserver">Identifying Peers</a> 41 </span> 42 </dt> 43 </dl> 44 </div> 45 <p> 46 It is possible to use a replica instead of a master to synchronize another 47 replica. This serves to take the request load off a master that might otherwise 48 occur if multiple replicas attempted to synchronize with the master at the same 49 time. 50 </p> 51 <p> 52 For best results, use this feature combined with the delayed synchronization 53 feature (see <a class="xref" href="addfeatures.html#delayedsync" title="Delayed Synchronization">Delayed Synchronization</a>). 54 </p> 55 <p> 56 For example, suppose your replication group consists of four environments. Upon 57 application startup, all three replicas will immediately attempt to synchronize 58 with the master. But at the same time, the master itself might be busy with a heavy 59 database write load. 60 </p> 61 <p> 62 To solve this problem, delay synchronization for two of the three replicas. Allow 63 the third replica to synchronize as normal with the master. Then, start 64 synchronization for each of the delayed replicas (since this is a manual process, 65 you can do them one at a time if that best suits your application). 66 Assuming you have configured replica to replica synchronization correctly, the 67 delayed replicas will synchronize using the up-to-date replica, rather than using 68 the master. 69 </p> 70 <p> 71 When you are using the Replication Manager, you configure replica to replica synchronization by 72 declaring one environment to be a peer of another environment. If an 73 environment is a peer, then 74 it can be used for synchronization purposes. 75 </p> 76 <div class="sect2" lang="en" xml:lang="en"> 77 <div class="titlepage"> 78 <div> 79 <div> 80 <h3 class="title"><a id="fmwrkpeerserver"></a>Identifying Peers</h3> 81 </div> 82 </div> 83 </div> 84 <p> 85 You can designate one replica to be a peer of 86 another for replica to replica synchronization. 87 You might want to do this if you have 88 machines that you know are on fast, reliable 89 network connections and so you are willing to 90 accept the overhead of waiting for 91 acknowledgments from those specific machines. 92 </p> 93 <p> 94 An environment is currently allowed to have only one 95 peer. 96 </p> 97 <p> 98 Note that peers are not required to be a 99 bi-directional. That is, just because machine A 100 declares machine B to be a peer, that does not mean 101 machine B must also declare machine A to be a peer. 102 </p> 103 <p> 104 You declare a peer for the current environment 105 when you add that environment to the list of known 106 sites. You do this by 107 <span>specifying the 108 <code class="literal">DB_REPMGR_PEER</code> flag to 109 110 <span><code class="methodname">DbEnv::repmgr_add_remote_site()</code>.</span> 111 </span> 112 113 </p> 114 </div> 115 </div> 116 <div class="navfooter"> 117 <hr /> 118 <table width="100%" summary="Navigation footer"> 119 <tr> 120 <td width="40%" align="left"><a accesskey="p" href="noautoinit.html">Prev</a>��</td> 121 <td width="20%" align="center"> 122 <a accesskey="u" href="addfeatures.html">Up</a> 123 </td> 124 <td width="40%" align="right">��<a accesskey="n" href="bulk.html">Next</a></td> 125 </tr> 126 <tr> 127 <td width="40%" align="left" valign="top">Stop Auto-Initialization��</td> 128 <td width="20%" align="center"> 129 <a accesskey="h" href="index.html">Home</a> 130 </td> 131 <td width="40%" align="right" valign="top">��Bulk Transfers</td> 132 </tr> 133 </table> 134 </div> 135 </body> 136</html> 137