diff --git a/doc/user/configuration-reference.xml b/doc/user/configuration-reference.xml
index 1263a661112b01f7ff03fffd6247762a7fad0a19..e4e08677aa786b37a71dc95e2b8bcb915abecd69 100644
--- a/doc/user/configuration-reference.xml
+++ b/doc/user/configuration-reference.xml
@@ -606,7 +606,10 @@ tarantool: box:primary@sessions pri:33013 sec:33014 adm:33015</programlisting>
         </row>
 
         <row>
-          <entry>replication_source_ipaddr</entry>
+          <entry xml:id="replication_source_ipaddr"
+                 xreflabel="replication_source_ipaddr">
+              replication_source_ipaddr
+          </entry>
           <entry>string</entry>
           <entry>0</entry>
           <entry>no</entry>
diff --git a/doc/user/html-highlight.xsl b/doc/user/html-highlight.xsl
index 30943c01d88011c2519f83fe8f56c24fee1885d6..02cb8b611b8213911cc5707cdf7f92d3472e0588 100644
--- a/doc/user/html-highlight.xsl
+++ b/doc/user/html-highlight.xsl
@@ -25,7 +25,7 @@ xmlns:xslthl="http://xslthl.sf.net" xmlns="http://www.w3.org/1999/xhtml" exclude
 </xsl:template>
 
 <xsl:template match="xslthl:comment" mode="xslthl">
-  <i class="hl-comment" style="color: blue"><xsl:apply-templates mode="xslthl"/></i>
+  <i class="hl-comment" style="color: silver"><xsl:apply-templates mode="xslthl"/></i>
 </xsl:template>
 
 <xsl:template match="xslthl:directive" mode="xslthl">
diff --git a/doc/user/language-reference.xml b/doc/user/language-reference.xml
index 5afa76682adf0a46e01e05ba31d32ecc61eaface..5163f54e41c8a9898efba6480d849b58c55f85aa 100644
--- a/doc/user/language-reference.xml
+++ b/doc/user/language-reference.xml
@@ -215,7 +215,26 @@ info:
   recovery_last_update: 1306964594.980
   status: primary
 </programlisting>
-      </para></listitem>
+      </para>
+      <para>
+        <emphasis role="strong">recovery_lag</emphasis> holds the
+        difference (in seconds) between the current time on the
+        machine (wall clock time) and the time stamp of the last
+        applied record.  In replication setup, this difference can
+        indicate the delay taking place before a change is
+        applied to a replica.
+      </para>
+      <para>
+        <emphasis role="strong">recovery_last_update</emphasis> is
+        the wall clock time of the last change recorded in the
+        write ahead log.
+      </para>
+      <para>
+        <emphasis role="strong">status</emphasis> is
+        either "primary" or "hot_standby/&lt;hostname&gt;".
+      </para>
+
+      </listitem>
     </varlistentry>
 
     <varlistentry>
@@ -240,12 +259,24 @@ statistics:
       <term xml:id="show-slab" xreflabel="SHOW SLAB">
         <emphasis role="tntadmin">show slab</emphasis>
       </term>
-      <listitem><para>
-        Show the statistics of slab allocator. The slab allocator
-        is the main allocator used to store tuples. This can be
-        used to monitor the total memory use and memory
-        fragmentation.
-      </para></listitem>
+      <listitem>
+        <para>
+          Show the statistics of the slab allocator. The slab
+          allocator is the main allocator used to store tuples.
+          This can be used to monitor the total memory use and
+          memory fragmentation.
+        </para>
+        <para>
+          <emphasis role="strong">items_used</emphasis> contains
+          the % of <olink targetptr="slab_alloc_arena"/> already
+          used to store tuples.
+        </para>
+        <para>
+          <emphasis role="strong">arena_used</emphasis> contains
+          the % of <olink targetptr="slab_alloc_arena"/> that is
+          already distributed to the slab allocator.
+        </para>
+      </listitem>
     </varlistentry>
 
     <varlistentry>
@@ -253,7 +284,7 @@ statistics:
         <emphasis role="tntadmin">show palloc</emphasis>
       </term>
       <listitem><para>
-        A pool allocator is used for temporary memory, when 
+        A pool allocator is used for temporary memory, when
         serving client requests. Every fiber has an own
         pool. Shows the current state of pools of all fibers.
       </para></listitem>
@@ -280,7 +311,6 @@ statistics:
       </para></listitem>
     </varlistentry>
 
-
   </variablelist>
 
 </section>
diff --git a/doc/user/namespace.xml b/doc/user/namespace.xml
index 1310bea3104cb10ced4f5c416971772a2a37e5ea..781a800174d4db5828e319d9c3fb04ccc3b33159 100644
--- a/doc/user/namespace.xml
+++ b/doc/user/namespace.xml
@@ -1,5 +1,5 @@
 <para xmlns="http://docbook.org/ns/docbook" version="5.0"
-      xmlns:xi="http://www.w3.org/2001/XInclude" 
+      xmlns:xi="http://www.w3.org/2001/XInclude"
       xmlns:xlink="http://www.w3.org/1999/xlink"
       xml:id="namespace">
 <bridgehead>Namespace settings explained</bridgehead>
@@ -59,11 +59,31 @@ a minimal storage configuration looks like below:
 <programlisting language="c">
 namespace[0].enabled = 1
 namespace[0].index[0].type = HASH
+namespace[0].index[0].unique = 1
 namespace[0].index[0].key_field[0].fieldno = 0
 namespace[0].index[0].key_field[0].type = NUM64
 </programlisting>
-Other namespace properties are set in the same way.
-When defining a namespace, please be aware of these restrictions:
+The parameters listed above are mandatory. Other namespace
+properties are set in the same way.
+An alternative syntax, mainly useful when defining large namespaces, exists:
+<programlisting language="c">
+namespace[0] = {
+    enabled = 1,
+    index = [
+        {
+            type = HASH,
+            key_field = [
+                {
+                    fieldno = 0,
+                    type = NUM64
+                }
+            ]
+        }
+    ]
+}
+</programlisting>
+When defining a namespace,
+please be aware of these restrictions:
 <itemizedlist>
   <listitem><simpara>at least one namespace must be
     configured,</simpara></listitem>
@@ -73,7 +93,7 @@ When defining a namespace, please be aware of these restrictions:
   <listitem><simpara>"unique" property doesn't have a default, and
     must be set explicitly,
   </simpara></listitem>
-  <listitem><simpara>namespace configuration can not be changed 
+  <listitem><simpara>namespace configuration can not be changed
     dynamically, currently you need to restart the server even to
     disable or enable a namespace,
   </simpara></listitem>
diff --git a/doc/user/replication.xml b/doc/user/replication.xml
index 78ef48bf1dc3f4e048964ffb58d3c5da9b744031..5d9dae315a8c8c7429a01b868f2dd28f9f496b5b 100644
--- a/doc/user/replication.xml
+++ b/doc/user/replication.xml
@@ -8,12 +8,142 @@
 
 <title>Replication</title>
 <blockquote><para>
-  How to set up replication?
+  To set up replication, it's necessary to prepare the master,
+  configure a replica, and establish procedures for recovery from
+  a degraded state.
 </para></blockquote>
 
-<para>
-Replication.
-</para>
+<section>
+  <title>Setting up the master</title>
+  <para>
+    To prepare the master for connections from replica, it's only
+    necessary to enable <olink targetptr="replication_port"/> in
+    the configuration file. An example configuration file can be
+    found in <link
+    xlink:href="https://github.com/mailru/tarantool/blob/master/test/box_replication/tarantool.cfg"><filename>test/box_replication/tarantool.cfg</filename></link>. A master with enabled replication_port can accept connections
+    from as many replicas as necessary on that port. Each replica
+    has its own replication state.
+  </para>
+</section>
+<section>
+  <title>Setting up a replica</title>
+  <para>
+    Replica gets all updates from the master by simply shipping
+    the write ahead log (WAL) and applying it.
+    Each record in the WAL has a log sequence number
+    (LSN), operation type (INSERT, UPDATE, DELETE) and a
+    timestamp.
+  </para>
+  <para>
+    For replication to work correctly, the latest LSN
+    on the replica must match or fall behind the latest LSN
+    on the master. If the replica has its own updates,
+    this leads to it getting out of sync since
+    updates from the master having identical LSNs are
+    not applied. Indeed, if replication is on, Tarantool
+    does not accept updates, even on its <olink
+    targetptr="primary_port"/>.
+  </para>
+  <para>
+    To "seed" a new replica, it's only necessary to
+    configure its <olink targetptr="replication_source_port"/>
+    and <olink targetptr="replication_source_ipaddr"/>.
+    These configuration parameters are "dynamic", which allows a
+    replica to become a master and vice versa with help of
+    <olink targetptr="reload-configuration"/> statement.
+    The replica uses these configuration parameters to
+    connect to the master, and request all changes that
+    happened after the latest local LSN. It is therefore
+    necessary to keep WAL files on the master host as long as
+    there are replicas that haven't applied them yet.
+    An example configuration can be found in <link
+    xlink:href="https://github.com/mailru/tarantool/blob/master/test/box_replication/tarantool_slave.cfg"><filename>test/box_replication/tarantool_slave.cfg</filename></link>.
+  </para>
+  <para>
+    In absence of WALs, a replica can be "seeded" at any time
+    with a snapshot file, manually copied from the master.
+  </para>
+
+</section>
+<section>
+  <title>Recovering from a degraded state</title>
+  <para>
+    "Degraded state" is a situation when the master becomes
+    unavailable -- either due to hardware or network failure, or a
+    programming bug. There is no reliable way for a replica to detect
+    that the master is gone for all, since sources of failure and
+    replication environments vary significantly.
+  </para>
+  <para>
+    A separate monitoring script (or scripts, if decision making
+    quorum is desirable) is necessary to detect a master failure.
+    Such script would typically try to update a tuple in an
+    auxiliary namespace on the master, and raise alarm if a
+    network or disk error persists longer than is acceptable.
+  </para>
+  <para>
+    When a master failure is detected, the following needs
+    to be done:
+    <itemizedlist>
+      <listitem>
+        <para>
+          First and foremost, make sure that the master does not
+          accepts updates. This is necessary to prevent the
+          situation when, should the master failure end up being
+          transient, some updates still go to the master, while
+          others already end up on the replica.
+        </para>
+        <para>
+          If the master is available, the easiest way to turn
+          on read-only mode is to turn Tarantool into a replica of
+          itself. This can be done by setting master's <olink
+          targetptr="replication_source_ipaddr"/> and <olink
+          targetptr="replication_source_port"/> to point to self.
+        </para>
+        <para>
+          If the master is not available, best bet is to log into
+          the machine and kill the server, or change the
+          machine's network configuration (DNS, IP address).
+        </para>
+        <para>
+          If the machine is not available, it's perhaps prudent
+          to power it off.
+        </para>
+      </listitem>
+      <listitem>
+        <para>
+          Record the replica's LSN, by issuing <olink
+          targetptr="show-info"/>. This LSN may prove useful if
+          there are updates on the master that never reached
+          the replica.
+        </para>
+      </listitem>
+      <listitem>
+        <para>
+          Propagate the replica to become a master. This is done
+          by setting <olink targetptr="replication_source_port"/>
+          on replica to <constant>0</constant>.
+        </para>
+      </listitem>
+      <listitem>
+        <para>
+          Change the application configuration to point to the new
+          master. This can be done either by changing the
+          application's internal routing table, or by setting up
+          old master's IP address on the new master's machine, or
+          using some other approach.
+        </para>
+      </listitem>
+      <listitem>
+        <para>
+          Recover the old master. If there are updates that didn't
+          make it to the new master, they have to be applied
+          manually.
+        </para>
+      </listitem>
+    </itemizedlist>
+  </para>
+</section>
 
 </chapter>
 
diff --git a/doc/user/target.db b/doc/user/target.db
index 2a03a467abf9b2d4e99300591370ab24f1d07fe5..be42aee5943d275781ba61599a36eec9be910dfb 100644
--- a/doc/user/target.db
+++ b/doc/user/target.db
@@ -1 +1 @@
-<div element="book" href="#tarantool-user-guide" number="" targetptr="tarantool-user-guide"><ttl>Tarantool/Box User Guide, version 1.4.1-32-g189b126</ttl><xreftext>Tarantool/Box User Guide, version 1.4.1-32-g189b126</xreftext><div element="chapter" href="#id496745" number="1"><ttl>Preface</ttl><xreftext>Chapter 1, <i>Preface</i></xreftext><div element="section" href="#preface" number="" targetptr="preface"><ttl>Tarantool/Box: an overview</ttl><xreftext>the section called “Tarantool/Box: an overview”</xreftext></div><div element="section" href="#id496788" number=""><ttl>Conventions</ttl><xreftext>the section called “Conventions”</xreftext></div><div element="section" href="#id496862" number=""><ttl>Reporting bugs</ttl><xreftext>the section called “Reporting bugs”</xreftext></div></div><div element="chapter" href="#id497986" number="2"><ttl>Getting started</ttl><xreftext>Chapter 2, <i>Getting started</i></xreftext></div><div element="chapter" href="#id499020" number="3"><ttl>Dynamic data model</ttl><xreftext>Chapter 3, <i>Dynamic data model</i></xreftext></div><div element="chapter" href="#language-reference" number="4" targetptr="language-reference"><ttl>Language reference</ttl><xreftext>Chapter 4, <i>Language reference</i></xreftext><div element="section" href="#id498712" number=""><ttl>Data manipulation</ttl><xreftext>the section called “Data manipulation”</xreftext><div element="section" href="#id499660" number=""><ttl>Memcached protocol</ttl><xreftext>the section called “Memcached protocol”</xreftext></div></div><div element="section" href="#id499689" number=""><ttl>Writing stored procedures in Lua</ttl><xreftext>the section called “Writing stored procedures in Lua”</xreftext></div><div element="section" href="#id499700" number=""><ttl>Administrative console</ttl><xreftext>the section called “Administrative console”</xreftext><obj element="emphasis" href="#reload-configuration" number="" targetptr="reload-configuration"><ttl>???TITLE???</ttl><xreftext>RELOAD CONFIGURATION</xreftext></obj><obj element="emphasis" href="#show-configuration" number="" targetptr="show-configuration"><ttl>???TITLE???</ttl><xreftext>SHOW CONFIGURATION</xreftext></obj><obj element="emphasis" href="#save-snapshot" number="" targetptr="save-snapshot"><ttl>???TITLE???</ttl><xreftext>SAVE SNAPSHOT</xreftext></obj></div></div><div element="chapter" href="#replication" number="5" targetptr="replication"><ttl>Replication</ttl><xreftext>Chapter 5, <i>Replication</i></xreftext></div><div element="chapter" href="#configuration-reference" number="6" targetptr="configuration-reference"><ttl>Configuration reference</ttl><xreftext>Chapter 6, <i>Configuration reference</i></xreftext><div element="section" href="#id498879" number=""><ttl>Command line options</ttl><xreftext>the section called “Command line options”</xreftext><obj element="listitem" href="#help-option" number="" targetptr="help-option"><ttl>???TITLE???</ttl><xreftext/></obj><obj element="listitem" href="#version-option" number="" targetptr="version-option"><ttl>???TITLE???</ttl><xreftext/></obj><obj element="listitem" href="#config-option" number="" targetptr="config-option"><ttl>???TITLE???</ttl><xreftext/></obj></div><div element="section" href="#option-file" number="" targetptr="option-file"><ttl>The option file</ttl><xreftext>option file</xreftext><obj element="table" href="#id501977" number="6.1"><ttl>Basic parameters</ttl><xreftext>Table 6.1, “Basic parameters”</xreftext></obj><obj element="entry" href="#wal_dir" number="" targetptr="wal_dir"><ttl>???TITLE???</ttl><xreftext>wal_dir</xreftext></obj><obj element="entry" href="#snap_dir" number="" targetptr="snap_dir"><ttl>???TITLE???</ttl><xreftext>snap_dir</xreftext></obj><obj element="entry" href="#primary_port" number="" targetptr="primary_port"><ttl>???TITLE???</ttl><xreftext>primary_port</xreftext></obj><obj element="entry" href="#secondary_port" number="" targetptr="secondary_port"><ttl>???TITLE???</ttl><xreftext>secondary_port</xreftext></obj><obj element="entry" href="#admin_port" number="" targetptr="admin_port"><ttl>???TITLE???</ttl><xreftext>admin_port</xreftext></obj><obj element="table" href="#id502371" number="6.2"><ttl>Configuring the storage</ttl><xreftext>Table 6.2, “Configuring the storage”</xreftext></obj><obj element="anchor" href="#slab_alloc_arena" number="" targetptr="slab_alloc_arena"><ttl>???TITLE???</ttl><xreftext>slab_alloc_arena</xreftext></obj><obj element="para" href="#namespace" number="" targetptr="namespace"><ttl>???TITLE???</ttl><xreftext>the section called “The option file”</xreftext></obj><obj element="table" href="#id502662" number="6.3"><ttl>Binary logging and snapshots</ttl><xreftext>Table 6.3, “Binary logging and snapshots”</xreftext></obj><obj element="table" href="#id502924" number="6.4"><ttl>Replication</ttl><xreftext>Table 6.4, “Replication”</xreftext></obj><obj element="entry" href="#replication_port" number="" targetptr="replication_port"><ttl>???TITLE???</ttl><xreftext>replication_port</xreftext></obj><obj element="entry" href="#replication_source_port" number="" targetptr="replication_source_port"><ttl>???TITLE???</ttl><xreftext>replication_source_port</xreftext></obj><obj element="table" href="#id503112" number="6.5"><ttl>Networking</ttl><xreftext>Table 6.5, “Networking”</xreftext></obj><obj element="table" href="#id503268" number="6.6"><ttl>Logging</ttl><xreftext>Table 6.6, “Logging”</xreftext></obj><obj element="table" href="#id503476" number="6.7"><ttl>Memcached protocol support</ttl><xreftext>Table 6.7, “Memcached protocol support”</xreftext></obj><obj element="anchor" href="#memcached_port" number="" targetptr="memcached_port"><ttl>???TITLE???</ttl><xreftext>memcached_port</xreftext></obj><obj element="anchor" href="#memcached_namespace" number="" targetptr="memcached_namespace"><ttl>???TITLE???</ttl><xreftext>memcached_namespace</xreftext></obj><obj element="anchor" href="#memcached_expire" number="" targetptr="memcached_expire"><ttl>???TITLE???</ttl><xreftext>memcached_expire</xreftext></obj></div></div><div element="chapter" href="#connectors" number="7" targetptr="connectors"><ttl>Connectors</ttl><xreftext>Chapter 7, <i>Connectors</i></xreftext><div element="section" href="#id501802" number=""><ttl>C</ttl><xreftext>the section called “C”</xreftext></div><div element="section" href="#id500225" number=""><ttl>Perl</ttl><xreftext>the section called “Perl”</xreftext></div><div element="section" href="#id500236" number=""><ttl>PHP</ttl><xreftext>the section called “PHP”</xreftext></div><div element="section" href="#id497412" number=""><ttl>Python</ttl><xreftext>the section called “Python”</xreftext></div><div element="section" href="#id497423" number=""><ttl>Ruby</ttl><xreftext>the section called “Ruby”</xreftext></div></div><div element="appendix" href="#errcode" number="A" targetptr="errcode"><ttl>List of error codes</ttl><xreftext>Appendix A, <i>List of error codes</i></xreftext><obj element="term" href="#ERR_CODE_NONMASTER" number="" targetptr="ERR_CODE_NONMASTER"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NONMASTER</xreftext></obj><obj element="term" href="#ERR_CODE_ILLEGAL_PARAMS" number="" targetptr="ERR_CODE_ILLEGAL_PARAMS"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_ILLEGAL_PARAMS</xreftext></obj><obj element="term" href="#ERR_CODE_NODE_IS_RO" number="" targetptr="ERR_CODE_NODE_IS_RO"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NODE_IS_RO</xreftext></obj><obj element="term" href="#ERR_CODE_MEMORY_ISSUE" number="" targetptr="ERR_CODE_MEMORY_ISSUE"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_MEMORY_ISSUE</xreftext></obj><obj element="term" href="#ERR_CODE_WAL_IO" number="" targetptr="ERR_CODE_WAL_IO"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_WAL_IO</xreftext></obj><obj element="term" href="#ERR_CODE_INDEX_VIOLATION" number="" targetptr="ERR_CODE_INDEX_VIOLATION"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_INDEX_VIOLATION</xreftext></obj><obj element="term" href="#ERR_CODE_NO_SUCH_NAMESPACE" number="" targetptr="ERR_CODE_NO_SUCH_NAMESPACE"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NO_SUCH_NAMESPACE</xreftext></obj><obj element="term" href="#ERR_CODE_NO_SUCH_INDEX" number="" targetptr="ERR_CODE_NO_SUCH_INDEX"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NO_SUCH_INDEX</xreftext></obj></div></div>
+<div element="book" href="#tarantool-user-guide" number="" targetptr="tarantool-user-guide"><ttl>Tarantool/Box User Guide, version 1.4.1-36-gc726afa</ttl><xreftext>Tarantool/Box User Guide, version 1.4.1-36-gc726afa</xreftext><div element="chapter" href="#id336243" number="1"><ttl>Preface</ttl><xreftext>Chapter 1, <i>Preface</i></xreftext><div element="section" href="#preface" number="" targetptr="preface"><ttl>Tarantool/Box: an overview</ttl><xreftext>the section called “Tarantool/Box: an overview”</xreftext></div><div element="section" href="#id336683" number=""><ttl>Conventions</ttl><xreftext>the section called “Conventions”</xreftext></div><div element="section" href="#id336756" number=""><ttl>Reporting bugs</ttl><xreftext>the section called “Reporting bugs”</xreftext></div></div><div element="chapter" href="#id337476" number="2"><ttl>Getting started</ttl><xreftext>Chapter 2, <i>Getting started</i></xreftext></div><div element="chapter" href="#id338516" number="3"><ttl>Dynamic data model</ttl><xreftext>Chapter 3, <i>Dynamic data model</i></xreftext></div><div element="chapter" href="#language-reference" number="4" targetptr="language-reference"><ttl>Language reference</ttl><xreftext>Chapter 4, <i>Language reference</i></xreftext><div element="section" href="#id338336" number=""><ttl>Data manipulation</ttl><xreftext>the section called “Data manipulation”</xreftext><div element="section" href="#id338388" number=""><ttl>Memcached protocol</ttl><xreftext>the section called “Memcached protocol”</xreftext></div></div><div element="section" href="#id336275" number=""><ttl>Writing stored procedures in Lua</ttl><xreftext>the section called “Writing stored procedures in Lua”</xreftext></div><div element="section" href="#id336286" number=""><ttl>Administrative console</ttl><xreftext>the section called “Administrative console”</xreftext><obj element="term" href="#save-snapshot" number="" targetptr="save-snapshot"><ttl>???TITLE???</ttl><xreftext>SAVE SNAPSHOT</xreftext></obj><obj element="term" href="#reload-configuration" number="" targetptr="reload-configuration"><ttl>???TITLE???</ttl><xreftext>RELOAD CONFIGURATION</xreftext></obj><obj element="term" href="#show-configuration" number="" targetptr="show-configuration"><ttl>???TITLE???</ttl><xreftext>SHOW CONFIGURATION</xreftext></obj><obj element="term" href="#show-info" number="" targetptr="show-info"><ttl>???TITLE???</ttl><xreftext>SHOW INFO</xreftext></obj><obj element="term" href="#show-stat" number="" targetptr="show-stat"><ttl>???TITLE???</ttl><xreftext>SHOW STAT</xreftext></obj><obj element="term" href="#show-slab" number="" targetptr="show-slab"><ttl>???TITLE???</ttl><xreftext>SHOW SLAB</xreftext></obj><obj element="term" href="#show-palloc" number="" targetptr="show-palloc"><ttl>???TITLE???</ttl><xreftext>SHOW PALLOC</xreftext></obj><obj element="term" href="#save-coredump" number="" targetptr="save-coredump"><ttl>???TITLE???</ttl><xreftext>SAVE COREDUMP</xreftext></obj><obj element="term" href="#show-fiber" number="" targetptr="show-fiber"><ttl>???TITLE???</ttl><xreftext>SHOW FIBER</xreftext></obj></div></div><div element="chapter" href="#replication" number="5" targetptr="replication"><ttl>Replication</ttl><xreftext>Chapter 5, <i>Replication</i></xreftext><div element="section" href="#id339061" number=""><ttl>Setting up the master</ttl><xreftext>the section called “Setting up the master”</xreftext></div><div element="section" href="#id339085" number=""><ttl>Setting up a replica</ttl><xreftext>the section called “Setting up a replica”</xreftext></div><div element="section" href="#id339141" number=""><ttl>Recovering from a degraded state</ttl><xreftext>the section called “Recovering from a degraded state”</xreftext></div></div><div element="chapter" href="#configuration-reference" number="6" targetptr="configuration-reference"><ttl>Configuration reference</ttl><xreftext>Chapter 6, <i>Configuration reference</i></xreftext><div element="section" href="#id341873" number=""><ttl>Command line options</ttl><xreftext>the section called “Command line options”</xreftext><obj element="listitem" href="#help-option" number="" targetptr="help-option"><ttl>???TITLE???</ttl><xreftext/></obj><obj element="listitem" href="#version-option" number="" targetptr="version-option"><ttl>???TITLE???</ttl><xreftext/></obj><obj element="listitem" href="#config-option" number="" targetptr="config-option"><ttl>???TITLE???</ttl><xreftext/></obj></div><div element="section" href="#option-file" number="" targetptr="option-file"><ttl>The option file</ttl><xreftext>option file</xreftext><obj element="table" href="#id341946" number="6.1"><ttl>Basic parameters</ttl><xreftext>Table 6.1, “Basic parameters”</xreftext></obj><obj element="entry" href="#wal_dir" number="" targetptr="wal_dir"><ttl>???TITLE???</ttl><xreftext>wal_dir</xreftext></obj><obj element="entry" href="#snap_dir" number="" targetptr="snap_dir"><ttl>???TITLE???</ttl><xreftext>snap_dir</xreftext></obj><obj element="entry" href="#primary_port" number="" targetptr="primary_port"><ttl>???TITLE???</ttl><xreftext>primary_port</xreftext></obj><obj element="entry" href="#secondary_port" number="" targetptr="secondary_port"><ttl>???TITLE???</ttl><xreftext>secondary_port</xreftext></obj><obj element="entry" href="#admin_port" number="" targetptr="admin_port"><ttl>???TITLE???</ttl><xreftext>admin_port</xreftext></obj><obj element="table" href="#id342340" number="6.2"><ttl>Configuring the storage</ttl><xreftext>Table 6.2, “Configuring the storage”</xreftext></obj><obj element="anchor" href="#slab_alloc_arena" number="" targetptr="slab_alloc_arena"><ttl>???TITLE???</ttl><xreftext>slab_alloc_arena</xreftext></obj><obj element="para" href="#namespace" number="" targetptr="namespace"><ttl>???TITLE???</ttl><xreftext>the section called “The option file”</xreftext></obj><obj element="table" href="#id342641" number="6.3"><ttl>Binary logging and snapshots</ttl><xreftext>Table 6.3, “Binary logging and snapshots”</xreftext></obj><obj element="table" href="#id342903" number="6.4"><ttl>Replication</ttl><xreftext>Table 6.4, “Replication”</xreftext></obj><obj element="entry" href="#replication_port" number="" targetptr="replication_port"><ttl>???TITLE???</ttl><xreftext>replication_port</xreftext></obj><obj element="entry" href="#replication_source_port" number="" targetptr="replication_source_port"><ttl>???TITLE???</ttl><xreftext>replication_source_port</xreftext></obj><obj element="entry" href="#replication_source_ipaddr" number="" targetptr="replication_source_ipaddr"><ttl>???TITLE???</ttl><xreftext>replication_source_ipaddr</xreftext></obj><obj element="table" href="#id343097" number="6.5"><ttl>Networking</ttl><xreftext>Table 6.5, “Networking”</xreftext></obj><obj element="table" href="#id343253" number="6.6"><ttl>Logging</ttl><xreftext>Table 6.6, “Logging”</xreftext></obj><obj element="table" href="#id343460" number="6.7"><ttl>Memcached protocol support</ttl><xreftext>Table 6.7, “Memcached protocol support”</xreftext></obj><obj element="anchor" href="#memcached_port" number="" targetptr="memcached_port"><ttl>???TITLE???</ttl><xreftext>memcached_port</xreftext></obj><obj element="anchor" href="#memcached_namespace" number="" targetptr="memcached_namespace"><ttl>???TITLE???</ttl><xreftext>memcached_namespace</xreftext></obj><obj element="anchor" href="#memcached_expire" number="" targetptr="memcached_expire"><ttl>???TITLE???</ttl><xreftext>memcached_expire</xreftext></obj></div></div><div element="chapter" href="#connectors" number="7" targetptr="connectors"><ttl>Connectors</ttl><xreftext>Chapter 7, <i>Connectors</i></xreftext><div element="section" href="#id340387" number=""><ttl>C</ttl><xreftext>the section called “C”</xreftext></div><div element="section" href="#id338448" number=""><ttl>Perl</ttl><xreftext>the section called “Perl”</xreftext></div><div element="section" href="#id338459" number=""><ttl>PHP</ttl><xreftext>the section called “PHP”</xreftext></div><div element="section" href="#id338470" number=""><ttl>Python</ttl><xreftext>the section called “Python”</xreftext></div><div element="section" href="#id338539" number=""><ttl>Ruby</ttl><xreftext>the section called “Ruby”</xreftext></div></div><div element="appendix" href="#errcode" number="A" targetptr="errcode"><ttl>List of error codes</ttl><xreftext>Appendix A, <i>List of error codes</i></xreftext><obj element="term" href="#ERR_CODE_NONMASTER" number="" targetptr="ERR_CODE_NONMASTER"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NONMASTER</xreftext></obj><obj element="term" href="#ERR_CODE_ILLEGAL_PARAMS" number="" targetptr="ERR_CODE_ILLEGAL_PARAMS"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_ILLEGAL_PARAMS</xreftext></obj><obj element="term" href="#ERR_CODE_NODE_IS_RO" number="" targetptr="ERR_CODE_NODE_IS_RO"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NODE_IS_RO</xreftext></obj><obj element="term" href="#ERR_CODE_MEMORY_ISSUE" number="" targetptr="ERR_CODE_MEMORY_ISSUE"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_MEMORY_ISSUE</xreftext></obj><obj element="term" href="#ERR_CODE_WAL_IO" number="" targetptr="ERR_CODE_WAL_IO"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_WAL_IO</xreftext></obj><obj element="term" href="#ERR_CODE_INDEX_VIOLATION" number="" targetptr="ERR_CODE_INDEX_VIOLATION"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_INDEX_VIOLATION</xreftext></obj><obj element="term" href="#ERR_CODE_NO_SUCH_NAMESPACE" number="" targetptr="ERR_CODE_NO_SUCH_NAMESPACE"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NO_SUCH_NAMESPACE</xreftext></obj><obj element="term" href="#ERR_CODE_NO_SUCH_INDEX" number="" targetptr="ERR_CODE_NO_SUCH_INDEX"><ttl>???TITLE???</ttl><xreftext>ERR_CODE_NO_SUCH_INDEX</xreftext></obj></div></div>
diff --git a/doc/user/tnt-html.xsl b/doc/user/tnt-html.xsl
index dd3ce1cbb9482e2c0e1409b7bcb60d88b56add1e..cf270d1d1b618f9e98a476f906578b65fd96211b 100644
--- a/doc/user/tnt-html.xsl
+++ b/doc/user/tnt-html.xsl
@@ -4,8 +4,8 @@
     xmlns:xslthl="http://xslthl.sf.net">
 
 <xsl:import href="http://docbook.sourceforge.net/release/xsl-ns/current/html/docbook.xsl"/> 
-<xsl:import href="html-highlight.xsl"/>
 
+<xsl:import href="html-highlight.xsl"/>
 
 <xsl:param name="generate.toc" select="'book toc'"/>
 <xsl:param name="html.stylesheet" select="'tnt.css'"/>