List:Commits« Previous MessageNext Message »
From:jon Date:August 29 2006 11:59am
Subject:svn commit - mysqldoc@docsrva: r3118 - trunk/refman-5.1
View as plain text  
Author: jstephens
Date: 2006-08-29 11:59:10 +0200 (Tue, 29 Aug 2006)
New Revision: 3118

Log:
More work on documenting NDB utils.

Modified:
   trunk/refman-5.1/ndb-utilities.xml


Modified: trunk/refman-5.1/ndb-utilities.xml
===================================================================
--- trunk/refman-5.1/ndb-utilities.xml	2006-08-29 09:58:03 UTC (rev 3117)
+++ trunk/refman-5.1/ndb-utilities.xml	2006-08-29 09:59:10 UTC (rev 3118)
Changed blocks: 7, Lines Added: 171, Lines Deleted: 21; 7587 bytes

@@ -215,7 +215,9 @@
 
     <para>
       <emphasis role="bold">Description</emphasis>: Deletes all rows
-      from the given table.
+      from the given <literal>NDB</literal> table. In some cases, this
+      can be much faster than <literal>DELETE</literal> or even
+      <literal>TRUNCATE</literal>. 
     </para>
 
     <para>

@@ -241,16 +243,6 @@
 
       <listitem>
         <para>
-          <option>-d</option>, <option>--database</option>
-        </para>
-
-        <para>
-          Indicates the database to which the table belongs.
-        </para>
-      </listitem>
-
-      <listitem>
-        <para>
           <option>-t</option>, <option>--transactional</option>
         </para>
 

@@ -420,8 +412,8 @@
     <para>
       <emphasis role="bold">Description</emphasis>: Drops the specified
       <literal>NDB</literal> table. This is extremely fast &mdash; an
-      order of magnitude faster than <literal>TRUNCATE</literal> in some
-      cases.
+      order of magnitude faster than <literal>DROP TABLE</literal> in
+      some cases.
     </para>
 
     <para>

@@ -433,7 +425,8 @@
 </programlisting>
 
     <para>
-      <emphasis role="bold">Additional Options</emphasis>:
+      <emphasis role="bold">Additional Options</emphasis>: None that are
+      specific to this application.
     </para>
 
   </section>

@@ -623,10 +616,18 @@
 
     <title><command>ndb_show_tables</command></title>
 
+    <remark role="todo">
+      [js] Remove references to Disk Data objects in the following for
+      the 4.1 and 5.0 versions.
+    </remark>
+
     <para>
       <emphasis role="bold">Description</emphasis>: Displays a list of
-      all <literal>NDB</literal> tables in the cluster. This includes
-      both user-created tables and <literal>NDB</literal> system tables.
+      all <literal>NDB</literal> database objects in the cluster. This
+      includes not only both user-created tables and
+      <literal>NDB</literal> system tables, but
+      <literal>NDB</literal>-specific indexes, internal triggers, and
+      Cluster Disk Data objects as well.
     </para>
 
     <para>

@@ -641,6 +642,91 @@
       <emphasis role="bold">Additional Options</emphasis>:
     </para>
 
+    <itemizedlist>
+
+      <listitem>
+        <para>
+          <option>-l</option>, <option>--loops</option>
+        </para>
+
+        <para>
+          Specifies the number of times the utility should execute. This
+          is 1 when this option is not specified, but if you do use the
+          option, you must supply an integer argument for it.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          <option>-p</option>, <option>--parsable</option>
+        </para>
+
+        <para>
+          Using this option causes the output to be in a format suitable
+          for use with <literal>LOAD DATA INFILE</literal>.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          <option>-t</option>, <option>--type</option>
+        </para>
+
+        <para>
+          Can be used to restrict the output to one type of object,
+          specified by an integer type code as shown here:
+        </para>
+
+        <itemizedlist>
+
+          <listitem>
+            <para>
+              <emphasis role="bold">1</emphasis>: System table
+            </para>
+          </listitem>
+
+          <listitem>
+            <para>
+              <emphasis role="bold">2</emphasis>: User-created table
+            </para>
+          </listitem>
+
+          <listitem>
+            <para>
+              <emphasis role="bold">3</emphasis>: Unique hash index
+            </para>
+          </listitem>
+
+        </itemizedlist>
+
+        <para>
+          Any other value causes all <literal>NDB</literal> database
+          objects to be listed (the default).
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          <option>-u</option>, <option>--unqualified</option>
+        </para>
+
+        <para>
+          If specified, this causes unqualified object names to be
+          displayed.
+        </para>
+      </listitem>
+
+    </itemizedlist>
+
+    <para>
+      <emphasis role="bold">Note</emphasis>: Only user-created Cluster
+      tables such as <literal>SYSTAB_0</literal> may be accessed from
+      MySQL. However, you can examine the contents of these tables using
+      <literal>NDB</literal> API applications such as
+      <command>ndb_select_all</command> (see
+      <xref linkend="mysql-cluster-utility-programs-ndb-select-all"/>).
+    </para>
+
   </section>
 
   <section id="mysql-cluster-utility-programs-ndb-size">

@@ -648,21 +734,85 @@
     <title><command>ndb_size.pl</command></title>
 
     <para>
-      <emphasis role="bold">Description</emphasis>:
+      <emphasis role="bold">Description</emphasis>: This is a Perl
+      script that can be used to estimate the amount of space that would
+      be required by a MySQL database if it were converted to use the
+      <literal>NDBCluster</literal> storage engine. Unlike the other
+      utilities discussed in this section, it does not require access to
+      a MySQL Cluster. However, it does need to access the MySQL server
+      on which the database to be tested resides.
     </para>
 
     <para>
-      <emphasis role="bold">Usage</emphasis>:
+      <emphasis role="bold">Requirements</emphasis>:
     </para>
 
-<programlisting>
+    <itemizedlist>
 
-</programlisting>
+      <listitem>
+        <para>
+          A running MySQL Server.
+        </para>
+      </listitem>
 
+      <listitem>
+        <para>
+          A working installation of Perl.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          The
+
+<literallayout>DBI</literallayout>
+
+          and <literal>HTML::Template</literal> libraries, both of which
+          can be obtained from CPAN if they are not already part of your
+          Perl installation.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          The <filename>ndb_size.tmpl</filename> template file, which
+          you should be able to find in the
+          <filename>share/mysql</filename> directory of your MySQL
+          installation.
+        </para>
+      </listitem>
+
+      <listitem>
+        <para>
+          A MySQL user account having the necessary privileges. If you
+          do not wish to use an existing account, then creating one
+          using <literal>GRANT USAGE ON
+          <replaceable>db_name</replaceable>.*</literal> &mdash; where
+          <replaceable>db_name</replaceable> is the name of the database
+          to be examined &mdash; is sufficient for this purpose.
+        </para>
+      </listitem>
+
+    </itemizedlist>
+
     <para>
-      <emphasis role="bold">Additional Options</emphasis>:
+      <filename>ndb_size.pl</filename> and
+      <filename>ndb_size.tmpl</filename> can also be found in the MySQL
+      sources in <filename>storage/ndb/tools</filename>. If these files
+      are not present in your MySQL installation, you can obtain them
+      from the
+      <ulink url="http://forge.mysql.com/projects/view.php?id=88">MySQLForge
+      project page</ulink>.
     </para>
 
+    <para>
+      <emphasis role="bold">Usage</emphasis>:
+    </para>
+
+<programlisting>
+ndb_size.pl <replaceable>db_name</replaceable> <replaceable>hostname</replaceable> <replaceable>user</replaceable> <replaceable>password</replaceable>
+</programlisting>
+
   </section>
 
   <section id="mysql-cluster-utility-programs-ndb-test-platform">


Thread
svn commit - mysqldoc@docsrva: r3118 - trunk/refman-5.1jon29 Aug