List:Commits« Previous MessageNext Message »
From:paul Date:January 30 2006 4:32am
Subject:svn commit - mysqldoc@docsrva: r1119 - in trunk: . refman-5.0 refman-5.1
View as plain text  
Author: paul
Date: 2006-01-30 05:32:17 +0100 (Mon, 30 Jan 2006)
New Revision: 1119

Log:
 r6889@frost:  paul | 2006-01-29 22:09:26 -0600
 General revisions.


Modified:
   trunk/
   trunk/refman-5.0/replication.xml
   trunk/refman-5.1/replication.xml


Property changes on: trunk
___________________________________________________________________
Name: svk:merge
   - b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:6888
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:2588
   + b5ec3a16-e900-0410-9ad2-d183a3acac99:/mysqldoc-local/mysqldoc/trunk:6889
bf112a9c-6c03-0410-a055-ad865cd57414:/mysqldoc-local/mysqldoc/trunk:2588

Modified: trunk/refman-5.0/replication.xml
===================================================================
--- trunk/refman-5.0/replication.xml	2006-01-30 04:32:03 UTC (rev 1118)
+++ trunk/refman-5.0/replication.xml	2006-01-30 04:32:17 UTC (rev 1119)
@@ -4398,21 +4398,15 @@
     </para>
 
     <para>
-      To accommodate multi-master replication with auto_increment, the
-      two system variables <literal>auto_increment_increment</literal>
-      and <literal>auto_increment_offset</literal> were introduced in
-      MySQL 5.0.2. Each of these variables has a default (and minimum)
-      value of 1, and a maximum value of 65,535.
+      The <literal>auto_increment_increment</literal> and
+      <literal>auto_increment_offset</literal> system variables help to
+      accommodate multiple-master replication with
+      <literal>AUTO_INCREMENT</literal> columns. Each of these variables
+      has a default and minimum value of 1, and a maximum value of
+      65,535. They were introduced in MySQL 5.0.2.
     </para>
 
     <para>
-      By setting non-conflicting values for these variables, servers in
-      a multi-master configuration will not use conflicting
-      <literal>AUTO_INCREMENT</literal> values when inserting new rows
-      into the same table.
-    </para>
-
-    <para>
       These two variables effect <literal>AUTO_INCREMENT</literal>
       column behavior as follows:
     </para>
@@ -4422,110 +4416,54 @@
       <listitem>
         <para>
           <literal>auto_increment_increment</literal> controls the
-          interval by which the column value is incremented. For
-          example:
+          increment between successive <literal>AUTO_INCREMENT</literal>
+          values.
         </para>
+      </listitem>
 
-<programlisting>
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 1     |
-| auto_increment_offset    | 1     |
-+--------------------------+-------+
-2 rows in set (0.00 sec)
+      <listitem>
+        <para>
+          <literal>auto_increment_offset</literal> determines the
+          starting point for <literal>AUTO_INCREMENT</literal> column
+          values.
+        </para>
+      </listitem>
 
-mysql&gt; <userinput>CREATE TABLE autoinc1</userinput>
-    -&gt; <userinput>(col INT NOT NULL AUTO_INCREMENT PRIMARY KEY);</userinput>
-Query OK, 0 rows affected (0.04 sec)
+    </itemizedlist>
 
-mysql&gt; <userinput>SET @@auto_increment_increment=10;</userinput>
-Query OK, 0 rows affected (0.00 sec)
+    <para>
+      By choosing non-conflicting values for these variables on
+      different masters, servers in a multiple-master configuration will
+      not use conflicting <literal>AUTO_INCREMENT</literal> values when
+      inserting new rows into the same table. To set up
+      <replaceable>N</replaceable> master servers, set the variables
+      like this:
+    </para>
 
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 10    |
-| auto_increment_offset    | 1     |
-+--------------------------+-------+
-2 rows in set (0.01 sec)
+    <itemizedlist>
 
-mysql&gt; <userinput>INSERT INTO autoinc1 VALUES (NULL), (NULL), (NULL), (NULL);</userinput>
-Query OK, 4 rows affected (0.00 sec)
-Records: 4  Duplicates: 0  Warnings: 0
-
-mysql&gt; <userinput>SELECT col FROM autoinc1;</userinput>
-+-----+
-| col |
-+-----+
-|   1 |
-|  11 |
-|  21 |
-|  31 |
-+-----+
-4 rows in set (0.00 sec)
-</programlisting>
-
+      <listitem>
         <para>
-          (Note how <literal>SHOW VARIABLES</literal> is used here to
-          obtain the current values for these variables.)
+          Set <literal>auto_increment_increment</literal> to
+          <replaceable>N</replaceable> on each master.
         </para>
       </listitem>
 
       <listitem>
         <para>
-          <literal>auto_increment_offset</literal> determines the
-          starting point for the <literal>AUTO_INCREMENT</literal>
-          column value. This affects how many masters you can have in
-          your replication setup (i.e. setting this value to 10 means
-          your setup can support up to ten servers).
+          Set each of the <replaceable>N</replaceable> masters to have a
+          different <literal>auto_increment_offset</literal>, using the
+          values 0, 1, 2, &hellip; ,
+          <replaceable>N</replaceable>&minus;1.
         </para>
-
-        <para>
-          Consider the following, assuming that these commands are
-          executed during the same session as the previous example:
-        </para>
-
-<programlisting>
-mysql&gt; <userinput>SET @@auto_increment_offset=5;</userinput>
-Query OK, 0 rows affected (0.00 sec)
-
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 10    |
-| auto_increment_offset    | 5     |
-+--------------------------+-------+
-2 rows in set (0.00 sec)
-
-mysql&gt; <userinput>CREATE TABLE autoinc2</userinput>
-    -&gt; <userinput>(col INT NOT NULL AUTO_INCREMENT PRIMARY KEY);</userinput>
-Query OK, 0 rows affected (0.06 sec)
-
-mysql&gt; <userinput>INSERT INTO autoinc2 VALUES (NULL), (NULL), (NULL), (NULL);</userinput>
-Query OK, 4 rows affected (0.00 sec)
-Records: 4  Duplicates: 0  Warnings: 0
-
-mysql&gt; <userinput>SELECT col FROM autoinc2;</userinput>
-+-----+
-| col |
-+-----+
-|   5 |
-|  15 |
-|  25 |
-|  35 |
-+-----+
-4 rows in set (0.02 sec)
-</programlisting>
       </listitem>
 
     </itemizedlist>
 
     <para>
-      For additional information see
+      For additional information about
+      <literal>auto_increment_increment</literal> and
+      <literal>auto_increment_offset</literal>, see
       <xref linkend="server-system-variables" />.
     </para>
 

Modified: trunk/refman-5.1/replication.xml
===================================================================
--- trunk/refman-5.1/replication.xml	2006-01-30 04:32:03 UTC (rev 1118)
+++ trunk/refman-5.1/replication.xml	2006-01-30 04:32:17 UTC (rev 1119)
@@ -4908,29 +4908,6 @@
       with as much information as possible.
     </para>
 
-    <para>
-      <emphasis role="bold">Q</emphasis>: How do I tell which format I'm
-      currently running (row-based or statement-based)?
-    </para>
-
-    <para>
-      <emphasis role="bold">A</emphasis>: By issuing this statement:
-    </para>
-
-<programlisting>
-mysql&gt; <userinput>SHOW VARIABLES LIKE "%binlog_format%";</userinput>
-</programlisting>
-
-    <para>
-      <emphasis role="bold">Q</emphasis>: How do I tell the slave to use
-      row-based replication?
-    </para>
-
-    <para>
-      <emphasis role="bold">A</emphasis>: The slave automatically knows
-      which format it should use.
-    </para>
-
   </section>
 
   <section id="replication-auto-increment">
@@ -4946,22 +4923,15 @@
     </para>
 
     <para>
-      The two system variables
-      <literal>auto_increment_increment</literal> and
-      <literal>auto_increment_offset</literal> help to accommodate
-      multi-master replication with <literal>AUTO_INCREMENT</literal>
-      columns. Each of these variables has a default (and minimum) value
-      of 1, and a maximum value of 65,535.
+      The <literal>auto_increment_increment</literal> and
+      <literal>auto_increment_offset</literal> system variables help to
+      accommodate multiple-master replication with
+      <literal>AUTO_INCREMENT</literal> columns. Each of these variables
+      has a default and minimum value of 1, and a maximum value of
+      65,535.
     </para>
 
     <para>
-      By setting non-conflicting values for these variables, servers in
-      a multi-master configuration will not use conflicting
-      <literal>AUTO_INCREMENT</literal> values when inserting new rows
-      into the same table.
-    </para>
-
-    <para>
       These two variables effect <literal>AUTO_INCREMENT</literal>
       column behavior as follows:
     </para>
@@ -4971,110 +4941,54 @@
       <listitem>
         <para>
           <literal>auto_increment_increment</literal> controls the
-          interval by which the column value is incremented. For
-          example:
+          increment between successive <literal>AUTO_INCREMENT</literal>
+          values.
         </para>
+      </listitem>
 
-<programlisting>
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 1     |
-| auto_increment_offset    | 1     |
-+--------------------------+-------+
-2 rows in set (0.00 sec)
+      <listitem>
+        <para>
+          <literal>auto_increment_offset</literal> determines the
+          starting point for <literal>AUTO_INCREMENT</literal> column
+          values.
+        </para>
+      </listitem>
 
-mysql&gt; <userinput>CREATE TABLE autoinc1</userinput>
-    -&gt; <userinput>(col INT NOT NULL AUTO_INCREMENT PRIMARY KEY);</userinput>
-Query OK, 0 rows affected (0.04 sec)
+    </itemizedlist>
 
-mysql&gt; <userinput>SET @@auto_increment_increment=10;</userinput>
-Query OK, 0 rows affected (0.00 sec)
+    <para>
+      By choosing non-conflicting values for these variables on
+      different masters, servers in a multiple-master configuration will
+      not use conflicting <literal>AUTO_INCREMENT</literal> values when
+      inserting new rows into the same table. To set up
+      <replaceable>N</replaceable> master servers, set the variables
+      like this:
+    </para>
 
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 10    |
-| auto_increment_offset    | 1     |
-+--------------------------+-------+
-2 rows in set (0.01 sec)
+    <itemizedlist>
 
-mysql&gt; <userinput>INSERT INTO autoinc1 VALUES (NULL), (NULL), (NULL), (NULL);</userinput>
-Query OK, 4 rows affected (0.00 sec)
-Records: 4  Duplicates: 0  Warnings: 0
-
-mysql&gt; <userinput>SELECT col FROM autoinc1;</userinput>
-+-----+
-| col |
-+-----+
-|   1 |
-|  11 |
-|  21 |
-|  31 |
-+-----+
-4 rows in set (0.00 sec)
-</programlisting>
-
+      <listitem>
         <para>
-          (Note how <literal>SHOW VARIABLES</literal> is used here to
-          obtain the current values for these variables.)
+          Set <literal>auto_increment_increment</literal> to
+          <replaceable>N</replaceable> on each master.
         </para>
       </listitem>
 
       <listitem>
         <para>
-          <literal>auto_increment_offset</literal> determines the
-          starting point for the <literal>AUTO_INCREMENT</literal>
-          column value. This affects how many masters you can have in
-          your replication setup (i.e. setting this value to 10 means
-          your setup can support up to ten servers).
+          Set each of the <replaceable>N</replaceable> masters to have a
+          different <literal>auto_increment_offset</literal>, using the
+          values 0, 1, 2, &hellip; ,
+          <replaceable>N</replaceable>&minus;1.
         </para>
-
-        <para>
-          Consider the following, assuming that these commands are
-          executed during the same session as the previous example:
-        </para>
-
-<programlisting>
-mysql&gt; <userinput>SET @@auto_increment_offset=5;</userinput>
-Query OK, 0 rows affected (0.00 sec)
-
-mysql&gt; <userinput>SHOW VARIABLES LIKE 'auto_inc%';</userinput>
-+--------------------------+-------+
-| Variable_name            | Value |
-+--------------------------+-------+
-| auto_increment_increment | 10    |
-| auto_increment_offset    | 5     |
-+--------------------------+-------+
-2 rows in set (0.00 sec)
-
-mysql&gt; <userinput>CREATE TABLE autoinc2</userinput>
-    -&gt; <userinput>(col INT NOT NULL AUTO_INCREMENT PRIMARY KEY);</userinput>
-Query OK, 0 rows affected (0.06 sec)
-
-mysql&gt; <userinput>INSERT INTO autoinc2 VALUES (NULL), (NULL), (NULL), (NULL);</userinput>
-Query OK, 4 rows affected (0.00 sec)
-Records: 4  Duplicates: 0  Warnings: 0
-
-mysql&gt; <userinput>SELECT col FROM autoinc2;</userinput>
-+-----+
-| col |
-+-----+
-|   5 |
-|  15 |
-|  25 |
-|  35 |
-+-----+
-4 rows in set (0.02 sec)
-</programlisting>
       </listitem>
 
     </itemizedlist>
 
     <para>
-      For additional information see
+      For additional information about
+      <literal>auto_increment_increment</literal> and
+      <literal>auto_increment_offset</literal>, see
       <xref linkend="server-system-variables" />.
     </para>
 

Thread
svn commit - mysqldoc@docsrva: r1119 - in trunk: . refman-5.0 refman-5.1paul30 Jan