Commit b6c814ac authored by unknown's avatar unknown

Imported freely distributable documentation from upstream MySQL 5.1.34 source tarball.

parent 54a04b00
You can find information about how to install binary distributions at
2.9. Installing MySQL from tar.gz Packages on Other Unix-Like Systems
http://dev.mysql.com/doc/refman/5.1/en/quick-standard-installation.html
This section covers the installation of MySQL binary distributions
that are provided for various platforms in the form of compressed
tar files (files with a .tar.gz extension). See Section 2.1.2.4,
"MySQL Binaries Compiled by Sun Microsystems, Inc.," for a
detailed list.
The MySQL Reference Manual is also available in various formats on
http://dev.mysql.com/doc; if you're interested in the DocBook XML
sources go to http://svn.mysql.com.
To obtain MySQL, see Section 2.1.3, "How to Get MySQL."
MySQL tar file binary distributions have names of the form
mysql-VERSION-OS.tar.gz, where VERSION is a number (for example,
5.1.35), and OS indicates the type of operating system for which
the distribution is intended (for example, pc-linux-i686).
In addition to these generic packages, we also offer binaries in
platform-specific package formats for selected platforms. See
Section 2.2, "Standard MySQL Installation Using a Binary
Distribution," for more information on how to install these.
You need the following tools to install a MySQL tar file binary
distribution:
* GNU gunzip to uncompress the distribution.
* A reasonable tar to unpack the distribution. GNU tar is known
to work. Some operating systems come with a preinstalled
version of tar that is known to have problems. For example,
the tar provided with early versions of Mac OS X, SunOS 4.x
and Solaris 8 and earlier are known to have problems with long
file names. On Mac OS X, you can use the preinstalled gnutar
program. On other systems with a deficient tar, you should
install GNU tar first.
If you run into problems and need to file a bug report, please use
the instructions in Section 1.6, "How to Report Bugs or Problems."
The basic commands that you must execute to install and use a
MySQL binary distribution are:
shell> groupadd mysql
shell> useradd -g mysql mysql
shell> cd /usr/local
shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
shell> ln -s full-path-to-mysql-VERSION-OS mysql
shell> cd mysql
shell> chown -R mysql .
shell> chgrp -R mysql .
shell> scripts/mysql_install_db --user=mysql
shell> chown -R root .
shell> chown -R mysql data
shell> bin/mysqld_safe --user=mysql &
Note
This procedure does not set up any passwords for MySQL accounts.
After following the procedure, proceed to Section 2.11,
"Post-Installation Setup and Testing."
A more detailed version of the preceding description for
installing a binary distribution follows:
1. Add a login user and group for mysqld to run as:
shell> groupadd mysql
shell> useradd -g mysql mysql
These commands add the mysql group and the mysql user. The
syntax for useradd and groupadd may differ slightly on
different versions of Unix, or they may have different names
such as adduser and addgroup.
You might want to call the user and group something else
instead of mysql. If so, substitute the appropriate name in
the following steps.
2. Pick the directory under which you want to unpack the
distribution and change location into it. In the following
example, we unpack the distribution under /usr/local. (The
instructions, therefore, assume that you have permission to
create files and directories in /usr/local. If that directory
is protected, you must perform the installation as root.)
shell> cd /usr/local
3. Obtain a distribution file using the instructions in Section
2.1.3, "How to Get MySQL." For a given release, binary
distributions for all platforms are built from the same MySQL
source distribution.
4. Unpack the distribution, which creates the installation
directory. Then create a symbolic link to that directory:
shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
shell> ln -s full-path-to-mysql-VERSION-OS mysql
The tar command creates a directory named mysql-VERSION-OS.
The ln command makes a symbolic link to that directory. This
lets you refer more easily to the installation directory as
/usr/local/mysql.
With GNU tar, no separate invocation of gunzip is necessary.
You can replace the first line with the following alternative
command to uncompress and extract the distribution:
shell> tar zxvf /path/to/mysql-VERSION-OS.tar.gz
5. Change location into the installation directory:
shell> cd mysql
You will find several files and subdirectories in the mysql
directory. The most important for installation purposes are
the bin and scripts subdirectories:
+ The bin directory contains client programs and the
server. You should add the full path name of this
directory to your PATH environment variable so that your
shell finds the MySQL programs properly. See Section
2.14, "Environment Variables."
+ The scripts directory contains the mysql_install_db
script used to initialize the mysql database containing
the grant tables that store the server access
permissions.
6. Ensure that the distribution contents are accessible to mysql.
If you unpacked the distribution as mysql, no further action
is required. If you unpacked the distribution as root, its
contents will be owned by root. Change its ownership to mysql
by executing the following commands as root in the
installation directory:
shell> chown -R mysql .
shell> chgrp -R mysql .
The first command changes the owner attribute of the files to
the mysql user. The second changes the group attribute to the
mysql group.
7. If you have not installed MySQL before, you must create the
MySQL data directory and initialize the grant tables:
shell> scripts/mysql_install_db --user=mysql
If you run the command as root, include the --user option as
shown. If you run the command while logged in as that user,
you can omit the --user option.
The command should create the data directory and its contents
with mysql as the owner.
After creating or updating the grant tables, you need to
restart the server manually.
8. Most of the MySQL installation can be owned by root if you
like. The exception is that the data directory must be owned
by mysql. To accomplish this, run the following commands as
root in the installation directory:
shell> chown -R root .
shell> chown -R mysql data
9. If you want MySQL to start automatically when you boot your
machine, you can copy support-files/mysql.server to the
location where your system has its startup files. More
information can be found in the support-files/mysql.server
script itself and in Section 2.11.2.2, "Starting and Stopping
MySQL Automatically."
10. You can set up new accounts using the bin/mysql_setpermission
script if you install the DBI and DBD::mysql Perl modules. See
Section 4.6.14, "mysql_setpermission --- Interactively Set
Permissions in Grant Tables." For Perl module installation
instructions, see Section 2.15, "Perl Installation Notes."
11. If you would like to use mysqlaccess and have the MySQL
distribution in some non-standard location, you must change
the location where mysqlaccess expects to find the mysql
client. Edit the bin/mysqlaccess script at approximately line
18. Search for a line that looks like this:
$MYSQL = '/usr/local/bin/mysql'; # path to mysql executable
Change the path to reflect the location where mysql actually
is stored on your system. If you do not do this, a Broken pipe
error will occur when you run mysqlaccess.
After everything has been unpacked and installed, you should test
your distribution. To start the MySQL server, use the following
command:
shell> bin/mysqld_safe --user=mysql &
If you run the command as root, you must use the --user option as
shown. The value of the option is the name of the login account
that you created in the first step to use for running the server.
If you run the command while logged in as mysql, you can omit the
--user option.
If the command fails immediately and prints mysqld ended, you can
find some information in the host_name.err file in the data
directory.
More information about mysqld_safe is given in Section 4.3.2,
"mysqld_safe --- MySQL Server Startup Script."
Note
The accounts that are listed in the MySQL grant tables initially
have no passwords. After starting the server, you should set up
passwords for them using the instructions in Section 2.11,
"Post-Installation Setup and Testing."
This diff is collapsed.
This diff is collapsed.
.\" Title: \fBcomp_err\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBCOMP_ERR\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
comp_err \- compile MySQL error message file
.SH "SYNOPSIS"
.HP 19
\fBcomp_err [\fR\fB\fIoptions\fR\fR\fB]\fR
.SH "DESCRIPTION"
.PP
\fBcomp_err\fR
creates the
\fIerrmsg.sys\fR
file that is used by
\fBmysqld\fR
to determine the error messages to display for different error codes.
\fBcomp_err\fR
normally is run automatically when MySQL is built. It compiles the
\fIerrmsg.sys\fR
file from the plaintext file located at
\fIsql/share/errmsg.txt\fR
in MySQL source distributions.
.PP
\fBcomp_err\fR
also generates
\fImysqld_error.h\fR,
\fImysqld_ername.h\fR, and
\fIsql_state.h\fR
header files.
.PP
For more information about how error messages are defined, see the MySQL Internals Manual.
.PP
Invoke
\fBcomp_err\fR
like this:
.sp
.RS 3n
.nf
shell> \fBcomp_err [\fR\fB\fIoptions\fR\fR\fB]\fR
.fi
.RE
.PP
\fBcomp_err\fR
understands the options described in the following list.
.TP 3n
\(bu
\fB\-\-help\fR,
\fB\-?\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-charset=\fR\fB\fIpath\fR\fR\fB, \-C \fR\fB\fIpath\fR\fR
.sp
The character set directory. The default is
\fI../sql/share/charsets\fR.
.TP 3n
\(bu
\fB\-\-debug=\fR\fB\fIdebug_options\fR\fR\fB, \-# \fR\fB\fIdebug_options\fR\fR
.sp
Write a debugging log. The
\fIdebug_options\fR
string often is
\'d:t:O,\fIfile_name\fR'. The default is
\'d:t:O,/tmp/comp_err.trace'.
.TP 3n
\(bu
\fB\-\-debug\-info\fR,
\fB\-T\fR
.sp
Print some debugging information when the program exits.
.TP 3n
\(bu
\fB\-\-header_file=\fR\fB\fIfile_name\fR\fR\fB, \-H \fR\fB\fIfile_name\fR\fR
.sp
The name of the error header file. The default is
\fImysqld_error.h\fR.
.TP 3n
\(bu
\fB\-\-in_file=\fR\fB\fIfile_name\fR\fR\fB, \-F \fR\fB\fIfile_name\fR\fR
.sp
The name of the input file. The default is
\fI../sql/share/errmsg.txt\fR.
.TP 3n
\(bu
\fB\-\-name_file=\fR\fB\fIfile_name\fR\fR\fB, \-N \fR\fB\fIfile_name\fR\fR
.sp
The name of the error name file. The default is
\fImysqld_ername.h\fR.
.TP 3n
\(bu
\fB\-\-out_dir=\fR\fB\fIpath\fR\fR\fB, \-D \fR\fB\fIpath\fR\fR
.sp
The name of the output base directory. The default is
\fI../sql/share/\fR.
.TP 3n
\(bu
\fB\-\-out_file=\fR\fB\fIfile_name\fR\fR\fB, \-O \fR\fB\fIfile_name\fR\fR
.sp
The name of the output file. The default is
\fIerrmsg.sys\fR.
.TP 3n
\(bu
\fB\-\-statefile=\fR\fB\fIfile_name\fR\fR\fB, \-S \fR\fB\fIfile_name\fR\fR
.sp
The name for the SQLSTATE header file. The default is
\fIsql_state.h\fR.
.TP 3n
\(bu
\fB\-\-version\fR,
\fB\-V\fR
.sp
Display version information and exit.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBinnochecksum\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBINNOCHECKSUM\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
innochecksum \- offline InnoDB file checksum utility
.SH "SYNOPSIS"
.HP 33
\fBinnochecksum [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIfile_name\fR\fR
.SH "DESCRIPTION"
.PP
\fBinnochecksum\fR
prints checksums for
InnoDB
files.
.PP
Invoke
\fBinnochecksum\fR
like this:
.sp
.RS 3n
.nf
shell> \fBinnochecksum [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIfile_name\fR\fR
.fi
.RE
.PP
\fBinnochecksum\fR
understands the options described in the following list. For options that refer to page numbers, the numbers are zero\-based.
.TP 3n
\(bu
\fB\-c\fR
.sp
Print a count of the number of pages in the file.
.TP 3n
\(bu
\fB\-d\fR
.sp
Debug mode; prints checksums for each page.
.TP 3n
\(bu
\fB\-e \fR\fB\fInum\fR\fR
.sp
End at this page number.
.TP 3n
\(bu
\fB\-p \fR\fB\fInum\fR\fR
.sp
Check only this page number.
.TP 3n
\(bu
\fB\-s \fR\fB\fInum\fR\fR
.sp
Start at this page number.
.TP 3n
\(bu
\fB\-v\fR
.sp
Verbose mode; print a progress indicator every five seconds.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmake_win_bin_dist\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMAKE_WIN_BIN_DIST" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
make_win_bin_dist \- package MySQL distribution as ZIP archive
.SH "SYNOPSIS"
.HP 60
\fBmake_win_bin_dist [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIpackage_basename\fR\fR\fB [\fR\fB\fIcopy_def\fR\fR\fB ...]\fR
.SH "DESCRIPTION"
.PP
This script is used on Windows after building a MySQL distribution from source to create executable programs. It packages the binaries and support files into a ZIP archive that can be unpacked at the location where you want to install MySQL.
.PP
\fBmake_win_bin_dist\fR
is a shell script, so you must have Cygwin installed to use it.
.PP
This program's use is subject to change. Currently, you invoke it as follows from the root directory of your source distribution:
.sp
.RS 3n
.nf
shell> \fBmake_win_bin_dist [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIpackage_basename\fR\fR\fB [\fR\fB\fIcopy_def\fR\fR\fB ...]\fR
.fi
.RE
.PP
The
\fIpackage_basename\fR
argument provides the basename for the resulting ZIP archive. This name will be the name of the directory that results from unpacking the archive.
.PP
Because you might want to include files of directories from other builds, you can instruct this script do copy them in for you, via
\fIcopy_def\fR
arguments, which of which is of the form
\fIrelative_dest_name\fR=\fIsource_name\fR.
.PP
Example:
.sp
.RS 3n
.nf
bin/mysqld\-max.exe=../my\-max\-build/sql/release/mysqld.exe
.fi
.RE
.PP
If you specify a directory, the entire directory will be copied.
.PP
\fBmake_win_bin_dist\fR
understands the following options:
.TP 3n
\(bu
\fB\-\-debug\fR
.sp
Pack the debug binaries and produce an error if they were not built.
.TP 3n
\(bu
\fB\-\-embedded\fR
.sp
Pack the embedded server and produce an error if it was not built. The default is to pack it if it was built.
.TP 3n
\(bu
\fB\-\-exe\-suffix=\fR\fB\fIsuffix\fR\fR
.sp
Add a suffix to the basename of the
\fBmysql\fR
binary. For example, a suffix of
\-abc
produces a binary named
\fBmysqld\-abc.exe\fR.
.TP 3n
\(bu
\fB\-\-no\-debug\fR
.sp
Don't pack the debug binaries even if they were built.
.TP 3n
\(bu
\fB\-\-no\-embedded\fR
.sp
Don't pack the embedded server even if it was built.
.TP 3n
\(bu
\fB\-\-only\-debug\fR
.sp
Use this option when the target for this build was
Debug, and you just want to replace the normal binaries with debug versions (that is, do not use separate
\fIdebug\fR
directories).
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmsql2mysql\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMSQL2MYSQL\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
msql2mysql \- convert mSQL programs for use with MySQL
.SH "SYNOPSIS"
.HP 28
\fBmsql2mysql\fR\fB\fIC\-source\-file\fR\fR\fB ...\fR
.SH "DESCRIPTION"
.PP
Initially, the MySQL C API was developed to be very similar to that for the mSQL database system. Because of this, mSQL programs often can be converted relatively easily for use with MySQL by changing the names of the C API functions.
.PP
The
\fBmsql2mysql\fR
utility performs the conversion of mSQL C API function calls to their MySQL equivalents.
\fBmsql2mysql\fR
converts the input file in place, so make a copy of the original before converting it. For example, use
\fBmsql2mysql\fR
like this:
.sp
.RS 3n
.nf
shell> \fBcp client\-prog.c client\-prog.c.orig\fR
shell> \fBmsql2mysql client\-prog.c\fR
client\-prog.c converted
.fi
.RE
.PP
Then examine
\fIclient\-prog.c\fR
and make any post\-conversion revisions that may be necessary.
.PP
\fBmsql2mysql\fR
uses the
\fBreplace\fR
utility to make the function name substitutions. See
\fBreplace\fR(1).
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmy_print_defaults\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMY_PRINT_DEFAULTS" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
my_print_defaults \- display options from option files
.SH "SYNOPSIS"
.HP 45
\fBmy_print_defaults [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIoption_group\fR\fR\fB ...\fR
.SH "DESCRIPTION"
.PP
\fBmy_print_defaults\fR
displays the options that are present in option groups of option files. The output indicates what options will be used by programs that read the specified option groups. For example, the
\fBmysqlcheck\fR
program reads the
[mysqlcheck]
and
[client]
option groups. To see what options are present in those groups in the standard option files, invoke
\fBmy_print_defaults\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmy_print_defaults mysqlcheck client\fR
\-\-user=myusername
\-\-password=secret
\-\-host=localhost
.fi
.RE
.PP
The output consists of options, one per line, in the form that they would be specified on the command line.
.PP
\fBmy_print_defaults\fR
understands the following options:
.TP 3n
\(bu
\fB\-\-help\fR,
\fB\-?\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-config\-file=\fR\fB\fIfile_name\fR\fR,
\fB\-\-defaults\-file=\fR\fB\fIfile_name\fR\fR,
\fB\-c \fR\fB\fIfile_name\fR\fR
.sp
Read only the given option file.
.TP 3n
\(bu
\fB\-\-debug=\fR\fB\fIdebug_options\fR\fR\fB, \-# \fR\fB\fIdebug_options\fR\fR
.sp
Write a debugging log. The
\fIdebug_options\fR
string often is
\'d:t:o,\fIfile_name\fR'. The default is
\'d:t:o,/tmp/my_print_defaults.trace'.
.TP 3n
\(bu
\fB\-\-defaults\-extra\-file=\fR\fB\fIfile_name\fR\fR,
\fB\-\-extra\-file=\fR\fB\fIfile_name\fR\fR,
\fB\-e \fR\fB\fIfile_name\fR\fR
.sp
Read this option file after the global option file but (on Unix) before the user option file.
.TP 3n
\(bu
\fB\-\-defaults\-group\-suffix=\fR\fB\fIsuffix\fR\fR,
\fB\-g \fR\fB\fIsuffix\fR\fR
.sp
In addition to the groups named on the command line, read groups that have the given suffix.
.TP 3n
\(bu
\fB\-\-no\-defaults\fR,
\fB\-n\fR
.sp
Return an empty string.
.TP 3n
\(bu
\fB\-\-verbose\fR,
\fB\-v\fR
.sp
Verbose mode. Print more information about what the program does.
.TP 3n
\(bu
\fB\-\-version\fR,
\fB\-V\fR
.sp
Display version information and exit.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmyisam_ftdump\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYISAM_FTDUMP\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
myisam_ftdump \- display full\-text index information
.SH "SYNOPSIS"
.HP 43
\fBmyisam_ftdump [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fItbl_name\fR\fR\fB \fR\fB\fIindex_num\fR\fR
.SH "DESCRIPTION"
.PP
\fBmyisam_ftdump\fR
displays information about
FULLTEXT
indexes in
MyISAM
tables. It reads the
MyISAM
index file directly, so it must be run on the server host where the table is located
.PP
Invoke
\fBmyisam_ftdump\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmyisam_ftdump [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fItbl_name\fR\fR\fB \fR\fB\fIindex_num\fR\fR
.fi
.RE
.PP
The
\fItbl_name\fR
argument should be the name of a
MyISAM
table. You can also specify a table by naming its index file (the file with the
\fI.MYI\fR
suffix). If you do not invoke
\fBmyisam_ftdump\fR
in the directory where the table files are located, the table or index file name must be preceded by the path name to the table's database directory. Index numbers begin with 0.
.PP
Example: Suppose that the
test
database contains a table named
mytexttablel
that has the following definition:
.sp
.RS 3n
.nf
CREATE TABLE mytexttable
(
id INT NOT NULL,
txt TEXT NOT NULL,
PRIMARY KEY (id),
FULLTEXT (txt)
);
.fi
.RE
.PP
The index on
id
is index 0 and the
FULLTEXT
index on
txt
is index 1. If your working directory is the
test
database directory, invoke
\fBmyisam_ftdump\fR
as follows:
.sp
.RS 3n
.nf
shell> \fBmyisam_ftdump mytexttable 1\fR
.fi
.RE
.PP
If the path name to the
test
database directory is
\fI/usr/local/mysql/data/test\fR, you can also specify the table name argument using that path name. This is useful if you do not invoke
\fBmyisam_ftdump\fR
in the database directory:
.sp
.RS 3n
.nf
shell> \fBmyisam_ftdump /usr/local/mysql/data/test/mytexttable 1\fR
.fi
.RE
.PP
\fBmyisam_ftdump\fR
understands the following options:
.TP 3n
\(bu
\fB\-\-help\fR,
\fB\-h\fR
\fB\-?\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-count\fR,
\fB\-c\fR
.sp
Calculate per\-word statistics (counts and global weights).
.TP 3n
\(bu
\fB\-\-dump\fR,
\fB\-d\fR
.sp
Dump the index, including data offsets and word weights.
.TP 3n
\(bu
\fB\-\-length\fR,
\fB\-l\fR
.sp
Report the length distribution.
.TP 3n
\(bu
\fB\-\-stats\fR,
\fB\-s\fR
.sp
Report global index statistics. This is the default operation if no other operation is specified.
.TP 3n
\(bu
\fB\-\-verbose\fR,
\fB\-v\fR
.sp
Verbose mode. Print more output about what the program does.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
This diff is collapsed.
.\" Title: \fBmyisamlog\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYISAMLOG\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
myisamlog \- display MyISAM log file contents
.SH "SYNOPSIS"
.HP 46
\fBmyisamlog [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fIlog_file\fR\fR\fB [\fR\fB\fItbl_name\fR\fR\fB] ...]\fR
.SH "DESCRIPTION"
.PP
\fBmyisamlog\fR
processes the contents of a
MyISAM
log file.
.PP
Invoke
\fBmyisamlog\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmyisamlog [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fIlog_file\fR\fR\fB [\fR\fB\fItbl_name\fR\fR\fB] ...]\fR
shell> \fBisamlog [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fIlog_file\fR\fR\fB [\fR\fB\fItbl_name\fR\fR\fB] ...]\fR
.fi
.RE
.PP
The default operation is update (\fB\-u\fR). If a recovery is done (\fB\-r\fR), all writes and possibly updates and deletes are done and errors are only counted. The default log file name is
\fImyisam.log\fR
for
\fBmyisamlog\fR
and
\fIisam.log\fR
for
\fBisamlog\fR
if no
\fIlog_file\fR
argument is given. If tables are named on the command line, only those tables are updated.
.PP
\fBmyisamlog\fR
understands the following options:
.TP 3n
\(bu
\fB\-?\fR,
\fB\-I\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-c \fR\fB\fIN\fR\fR
.sp
Execute only
\fIN\fR
commands.
.TP 3n
\(bu
\fB\-f \fR\fB\fIN\fR\fR
.sp
Specify the maximum number of open files.
.TP 3n
\(bu
\fB\-i\fR
.sp
Display extra information before exiting.
.TP 3n
\(bu
\fB\-o \fR\fB\fIoffset\fR\fR
.sp
Specify the starting offset.
.TP 3n
\(bu
\fB\-p \fR\fB\fIN\fR\fR
.sp
Remove
\fIN\fR
components from path.
.TP 3n
\(bu
\fB\-r\fR
.sp
Perform a recovery operation.
.TP 3n
\(bu
\fB\-R \fR\fB\fIrecord_pos_file record_pos\fR\fR
.sp
Specify record position file and record position.
.TP 3n
\(bu
\fB\-u\fR
.sp
Perform an update operation.
.TP 3n
\(bu
\fB\-v\fR
.sp
Verbose mode. Print more output about what the program does. This option can be given multiple times to produce more and more output.
.TP 3n
\(bu
\fB\-w \fR\fB\fIwrite_file\fR\fR
.sp
Specify the write file.
.TP 3n
\(bu
\fB\-V\fR
.sp
Display version information.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
This diff is collapsed.
.\" Title: \fBmysql\-stress\-test.pl\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/27/2009
.\" Manual: MySQL Database System
.\" Source: MySQL
.\"
.TH "\fBMYSQL\-STRESS\-TEST" "1" "03/27/2009" "MySQL" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql\-stress\-test.pl \- server stress test program
.SH "SYNOPSIS"
.HP 31
\fBmysql\-stress\-test.pl [\fR\fB\fIoptions\fR\fR\fB]\fR
.SH "DESCRIPTION"
.PP
The
\fBmysql\-stress\-test.pl\fR
Perl script performs stress\-testing of the MySQL server. (MySQL 5.0 and up only)
.PP
\fBmysql\-stress\-test.pl\fR
requires a version of Perl that has been built with threads support.
.PP
Invoke
\fBmysql\-stress\-test.pl\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmysql\-stress\-test.pl [\fR\fB\fIoptions\fR\fR\fB]\fR
.fi
.RE
.PP
\fBmysql\-stress\-test.pl\fR
supports the following options:
.TP 3n
\(bu
\fB\-\-help\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-abort\-on\-error\fR
.sp
Unknown.
.TP 3n
\(bu
\fB\-\-check\-tests\-file\fR
.sp
Periodically check the file that lists the tests to be run. If it has been modified, reread the file. This can be useful if you update the list of tests to be run during a stress test.
.TP 3n
\(bu
\fB\-\-cleanup\fR
.sp
Force cleanup of the working directory.
.TP 3n
\(bu
\fB\-\-log\-error\-details\fR
.sp
Log error details in the global error log file.
.TP 3n
\(bu
\fB\-\-loop\-count=\fR\fB\fIN\fR\fR
.sp
In sequential test mode, the number of loops to execute before exiting.
.TP 3n
\(bu
\fB\-\-mysqltest=\fR\fB\fIpath\fR\fR
.sp
The path name to the
\fBmysqltest\fR
program.
.TP 3n
\(bu
\fB\-\-server\-database=\fR\fB\fIdb_name\fR\fR
.sp
The database to use for the tests.
.TP 3n
\(bu
\fB\-\-server\-host=\fR\fB\fIhost_name\fR\fR
.sp
The host name of the local host to use for making a TCP/IP connection to the local server. By default, the connection is made to
localhost
using a Unix socket file.
.TP 3n
\(bu
\fB\-\-server\-logs\-dir=\fR\fB\fIpath\fR\fR
.sp
This option is required.
\fIpath\fR
is the directory where all client session logs will be stored. Usually this is the shared directory that is associated with the server used for testing.
.TP 3n
\(bu
\fB\-\-server\-password=\fR\fB\fIpassword\fR\fR
.sp
The password to use when connecting to the server.
.TP 3n
\(bu
\fB\-\-server\-port=\fR\fB\fIport_num\fR\fR
.sp
The TCP/IP port number to use for connecting to the server. The default is 3306.
.TP 3n
\(bu
\fB\-\-server\-socket=\fR\fB\fIfile_name\fR\fR
.sp
For connections to
localhost, the Unix socket file to use, or, on Windows, the name of the named pipe to use. The default if
\fI/tmp/mysql.sock\fR.
.TP 3n
\(bu
\fB\-\-server\-user=\fR\fB\fIuser_name\fR\fR
.sp
The MySQL user name to use when connecting to the server. The default is
root.
.TP 3n
\(bu
\fB\-\-sleep\-time=\fR\fB\fIN\fR\fR
.sp
The delay in seconds between test executions.
.TP 3n
\(bu
\fB\-\-stress\-basedir=\fR\fB\fIpath\fR\fR
.sp
This option is required.
\fIpath\fR
is the working directory for the test run. It is used as the temporary location for result tracking during testing.
.TP 3n
\(bu
\fB\-\-stress\-datadir=\fR\fB\fIpath\fR\fR
.sp
The directory of data files to be used during testing. The default location is the
\fIdata\fR
directory under the location given by the
\fB\-\-stress\-suite\-basedir\fR
option.
.TP 3n
\(bu
\fB\-\-stress\-init\-file[=\fR\fB\fIpath\fR\fR\fB]\fR
.sp
\fIfile_name\fR
is the location of the file that contains the list of tests. If missing, the default file is
\fIstress_init.txt\fR
in the test suite directory.
.TP 3n
\(bu
\fB\-\-stress\-mode=\fR\fB\fImode\fR\fR
.sp
This option indicates the test order in stress\-test mode. The
\fImode\fR
value is either
random
to select tests in random order or
seq
to run tests in each thread in the order specified in the test list file. The default mode is
random.
.TP 3n
\(bu
\fB\-\-stress\-suite\-basedir=\fR\fB\fIpath\fR\fR
.sp
This option is required.
\fIpath\fR
is the directory that has the
\fIt\fR
and
\fIr\fR
subdirectories containing the test case and result files. This directory is also the default location of the
\fIstress\-test.txt\fR
file that contains the list of tests. (A different location can be specified with the
\fB\-\-stress\-tests\-file\fR
option.)
.TP 3n
\(bu
\fB\-\-stress\-tests\-file[=\fR\fB\fIfile_name\fR\fR\fB]\fR
.sp
Use this option to run the stress tests.
\fIfile_name\fR
is the location of the file that contains the list of tests. If
\fIfile_name\fR
is omitted, the default file is
\fIstress\-test.txt\fR
in the stress suite directory. (See
\fB\-\-stress\-suite\-basedir\fR.)
.TP 3n
\(bu
\fB\-\-suite=\fR\fB\fIsuite_name\fR\fR
.sp
Run the named test suite. The default name is
main
(the regular test suite located in the
\fImysql\-test\fR
directory).
.TP 3n
\(bu
\fB\-\-test\-count=\fR\fB\fIN\fR\fR
.sp
The number of tests to execute before exiting.
.TP 3n
\(bu
\fB\-\-test\-duration=\fR\fB\fIN\fR\fR
.sp
The duration of stress testing in seconds.
.TP 3n
\(bu
\fB\-\-test\-suffix=\fR\fB\fIstr\fR\fR
.sp
Unknown.
.TP 3n
\(bu
\fB\-\-threads=\fR\fB\fIN\fR\fR
.sp
The number of threads. The default is 1.
.TP 3n
\(bu
\fB\-\-verbose\fR
.sp
Verbose mode. Print more information about what the program does.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
This diff is collapsed.
This diff is collapsed.
.\" Title: \fBmysql.server\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL.SERVER\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql.server \- MySQL server startup script
.SH "SYNOPSIS"
.HP 19
\fBmysql {start|stop}\fR
.SH "DESCRIPTION"
.PP
MySQL distributions on Unix include a script named
\fBmysql.server\fR. It can be used on systems such as Linux and Solaris that use System V\-style run directories to start and stop system services. It is also used by the Mac OS X Startup Item for MySQL.
.PP
\fBmysql.server\fR
can be found in the
\fIsupport\-files\fR
directory under your MySQL installation directory or in a MySQL source distribution.
.PP
If you use the Linux server RPM package (MySQL\-server\-\fIVERSION\fR.rpm), the
\fBmysql.server\fR
script will be installed in the
\fI/etc/init.d\fR
directory with the name
\fImysql\fR. You need not install it manually. See
Section\ 2.4, \(lqInstalling MySQL from RPM Packages on Linux\(rq, for more information on the Linux RPM packages.
.PP
Some vendors provide RPM packages that install a startup script under a different name such as
\fBmysqld\fR.
.PP
If you install MySQL from a source distribution or using a binary distribution format that does not install
\fBmysql.server\fR
automatically, you can install it manually. Instructions are provided in
Section\ 2.11.2.2, \(lqStarting and Stopping MySQL Automatically\(rq.
.PP
\fBmysql.server\fR
reads options from the
[mysql.server]
and
[mysqld]
sections of option files. For backward compatibility, it also reads
[mysql_server]
sections, although you should rename such sections to
[mysql.server]
when using MySQL 5.1.
.PP
\fBmysql.server\fR
understands the following options:
.TP 3n
\(bu
\fB\-\-basedir=\fR\fB\fIpath\fR\fR
.sp
The path to the MySQL installation directory.
.TP 3n
\(bu
\fB\-\-datadir=\fR\fB\fIpath\fR\fR
.sp
The path to the MySQL data directory.
.TP 3n
\(bu
\fB\-\-pid\-file=\fR\fB\fIfile_name\fR\fR
.sp
The path name of the file in which the server should write its process ID.
.TP 3n
\(bu
\fB\-\-service\-startup\-timeout=\fR\fB\fIfile_name\fR\fR
.sp
How long in seconds to wait for confirmation of server startup. If the server does not start within this time,
\fBmysql.server\fR
exits with an error. The default value is 900. A value of 0 means not to wait at all for startup. Negative values mean to wait forever (no timeout). This option was added in MySQL 5.1.17. Before that, a value of 900 is always used.
.TP 3n
\(bu
\fB\-\-use\-mysqld_safe\fR
.sp
Use
\fBmysqld_safe\fR
to start the server. This is the default.
.TP 3n
\(bu
\fB\-\-use\-manager\fR
.sp
Use Instance Manager to start the server.
.TP 3n
\(bu
\fB\-\-user=\fR\fB\fIuser_name\fR\fR
.sp
The login user name to use for running
\fBmysqld\fR.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_client_test\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/27/2009
.\" Manual: MySQL Database System
.\" Source: MySQL
.\"
.TH "\fBMYSQL_CLIENT_TEST" "1" "03/27/2009" "MySQL" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_client_test \- test client API
.br
mysql_client_test_embedded \- test client API for embedded server
.SH "SYNOPSIS"
.HP 44
\fBmysql_client_test [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fItest_name\fR\fR\fB] ...\fR
.HP 53
\fBmysql_client_test_embedded [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fItest_name\fR\fR\fB] ...\fR
.SH "DESCRIPTION"
.PP
The
\fBmysql_client_test\fR
program is used for testing aspects of the MySQL client API that cannot be tested using
\fBmysqltest\fR
and its test language.
\fBmysql_client_test_embedded\fR
is similar but used for testing the embedded server. Both programs are run as part of the test suite.
.PP
The source code for the programs can be found in in
\fItest/mysql_client_test.c\fR
in a source distribution. The program serves as a good source of examples illustrating how to use various features of the client API.
.PP
\fBmysql_client_test\fR
supports the following options:
.TP 3n
\(bu
\fB\-\-help\fR,
\fB\-?\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-b \fR\fB\fIdir_name\fR\fR,
\fB\-\-basedir=\fR\fB\fIdir_name\fR\fR
.sp
The base directory for the tests.
.TP 3n
\(bu
\fB\-t \fR\fB\fIcount\fR\fR,
\fB\-\-count=\fR\fB\fIcount\fR\fR
.sp
The number of times to execute the tests.
.TP 3n
\(bu
\fB\-\-database=\fR\fB\fIdb_name\fR\fR,
\fB\-D \fR\fB\fIdb_name\fR\fR
.sp
The database to use.
.TP 3n
\(bu
\fB\-\-debug[=\fR\fB\fIdebug_options\fR\fR\fB]\fR,
\fB\-#[\fR\fB\fIdebug_options\fR\fR\fB]\fR
.sp
Write a debugging log if MySQL is built with debugging support. The default
\fIdebug_options\fR
value is
\'d:t:o,/tmp/mysql_client_test.trace'.
.TP 3n
\(bu
\fB\-g \fR\fB\fIoption\fR\fR,
\fB\-\-getopt\-ll\-test=\fR\fB\fIoption\fR\fR
.sp
Option to use for testing bugs in the
getopt
library.
.TP 3n
\(bu
\fB\-\-host=\fR\fB\fIhost_name\fR\fR,
\fB\-h \fR\fB\fIhost_name\fR\fR
.sp
Connect to the MySQL server on the given host.
.TP 3n
\(bu
\fB\-\-password[=\fR\fB\fIpassword\fR\fR\fB]\fR,
\fB\-p[\fR\fB\fIpassword\fR\fR\fB]\fR
.sp
The password to use when connecting to the server. If you use the short option form (\fB\-p\fR), you
\fIcannot\fR
have a space between the option and the password. If you omit the
\fIpassword\fR
value following the
\fB\-\-password\fR
or
\fB\-p\fR
option on the command line, you are prompted for one.
.TP 3n
\(bu
\fB\-\-port=\fR\fB\fIport_num\fR\fR,
\fB\-P \fR\fB\fIport_num\fR\fR
.sp
The TCP/IP port number to use for the connection.
.TP 3n
\(bu
\fB\-A \fR\fB\fIarg\fR\fR,
\fB\-\-server\-arg=\fR\fB\fIarg\fR\fR
.sp
Argument to send to the embedded server.
.TP 3n
\(bu
\fB\-T\fR,
\fB\-\-show\-tests\fR
.sp
Show all test names.
.TP 3n
\(bu
\fB\-\-silent\fR,
\fB\-s\fR
.sp
Be more silent.
.TP 3n
\(bu
\fB\-\-socket=\fR\fB\fIpath\fR\fR,
\fB\-S \fR\fB\fIpath\fR\fR
.sp
The socket file to use when connecting to
localhost
(which is the default host).
.TP 3n
\(bu
\fB\-c\fR,
\fB\-\-testcase\fR
.sp
The option may disable some code when run as a
\fBmysql\-test\-run.pl\fR
test case.
.TP 3n
\(bu
\fB\-\-user=\fR\fB\fIuser_name\fR\fR,
\fB\-u \fR\fB\fIuser_name\fR\fR
.sp
The MySQL user name to use when connecting to the server.
.TP 3n
\(bu
\fB\-v \fR\fB\fIdir_name\fR\fR,
\fB\-\-vardir=\fR\fB\fIdir_name\fR\fR
.sp
The data directory for tests. The default is
\fImysql\-test/var\fR.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.so man1/mysql_client_test.1
.\" Title: \fBmysql_config\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_CONFIG\fR" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_config \- get compile options for compiling clients
.SH "SYNOPSIS"
.HP 21
\fBmysql_config \fR\fB\fIoptions\fR\fR
.SH "DESCRIPTION"
.PP
\fBmysql_config\fR
provides you with useful information for compiling your MySQL client and connecting it to MySQL.
.PP
\fBmysql_config\fR
supports the following options:
.TP 3n
\(bu
\fB\-\-cflags\fR
.sp
Compiler flags to find include files and critical compiler flags and defines used when compiling the
libmysqlclient
library. The options returned are tied to the specific compiler that was used when the library was created and might clash with the settings for your own compiler. Use
\fB\-\-include\fR
for more portable options that contain only include paths.
.TP 3n
\(bu
\fB\-\-include\fR
.sp
Compiler options to find MySQL include files.
.TP 3n
\(bu
\fB\-\-libmysqld\-libs\fR,
\fB\-\-embedded\fR
.sp
Libraries and options required to link with the MySQL embedded server.
.TP 3n
\(bu
\fB\-\-libs\fR
.sp
Libraries and options required to link with the MySQL client library.
.TP 3n
\(bu
\fB\-\-libs_r\fR
.sp
Libraries and options required to link with the thread\-safe MySQL client library.
.TP 3n
\(bu
\fB\-\-plugindir\fR
.sp
The default plugin directory path name, defined when configuring MySQL. This option was added in MySQL 5.1.24.
.TP 3n
\(bu
\fB\-\-port\fR
.sp
The default TCP/IP port number, defined when configuring MySQL.
.TP 3n
\(bu
\fB\-\-socket\fR
.sp
The default Unix socket file, defined when configuring MySQL.
.TP 3n
\(bu
\fB\-\-version\fR
.sp
Version number for the MySQL distribution.
.sp
.RE
.PP
If you invoke
\fBmysql_config\fR
with no options, it displays a list of all options that it supports, and their values:
.sp
.RS 3n
.nf
shell> \fBmysql_config\fR
Usage: /usr/local/mysql/bin/mysql_config [options]
Options:
\-\-cflags [\-I/usr/local/mysql/include/mysql \-mcpu=pentiumpro]
\-\-include [\-I/usr/local/mysql/include/mysql]
\-\-libs [\-L/usr/local/mysql/lib/mysql \-lmysqlclient \-lz
\-lcrypt \-lnsl \-lm \-L/usr/lib \-lssl \-lcrypto]
\-\-libs_r [\-L/usr/local/mysql/lib/mysql \-lmysqlclient_r
\-lpthread \-lz \-lcrypt \-lnsl \-lm \-lpthread]
\-\-socket [/tmp/mysql.sock]
\-\-port [3306]
\-\-version [4.0.16]
\-\-libmysqld\-libs [\-L/usr/local/mysql/lib/mysql \-lmysqld \-lpthread \-lz
\-lcrypt \-lnsl \-lm \-lpthread \-lrt]
.fi
.RE
.PP
You can use
\fBmysql_config\fR
within a command line to include the value that it displays for a particular option. For example, to compile a MySQL client program, use
\fBmysql_config\fR
as follows:
.sp
.RS 3n
.nf
shell> \fBCFG=/usr/local/mysql/bin/mysql_config\fR
shell> \fBsh \-c "gcc \-o progname `$CFG \-\-include` progname.c `$CFG \-\-libs`"\fR
.fi
.RE
.PP
When you use
\fBmysql_config\fR
this way, be sure to invoke it within backtick (\(lq`\(rq) characters. That tells the shell to execute it and substitute its output into the surrounding command.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_convert_table_format\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_CONVERT_TAB" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_convert_table_format \- convert tables to use a given storage engine
.SH "SYNOPSIS"
.HP 45
\fBmysql_convert_table_format [\fR\fB\fIoptions\fR\fR\fB] \fR\fB\fIdb_name\fR\fR
.SH "DESCRIPTION"
.PP
\fBmysql_convert_table_format\fR
converts the tables in a database to use a particular storage engine (MyISAM
by default).
\fBmysql_convert_table_format\fR
is written in Perl and requires that the
DBI
and
DBD::mysql
Perl modules be installed (see
Section\ 2.15, \(lqPerl Installation Notes\(rq).
.PP
Invoke
\fBmysql_convert_table_format\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmysql_convert_table_format [\fR\fB\fIoptions\fR\fR\fB]\fR\fB\fIdb_name\fR\fR
.fi
.RE
.PP
The
\fIdb_name\fR
argument indicates the database containing the tables to be converted.
.PP
\fBmysql_convert_table_format\fR
understands the options described in the following list.
.TP 3n
\(bu
\fB\-\-help\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-force\fR
.sp
Continue even if errors occur.
.TP 3n
\(bu
\fB\-\-host=\fR\fB\fIhost_name\fR\fR
.sp
Connect to the MySQL server on the given host.
.TP 3n
\(bu
\fB\-\-password=\fR\fB\fIpassword\fR\fR
.sp
The password to use when connecting to the server. Note that the password value is not optional for this option, unlike for other MySQL programs. You can use an option file to avoid giving the password on the command line.
.sp
Specifying a password on the command line should be considered insecure. See
Section\ 5.5.6.2, \(lqEnd\-User Guidelines for Password Security\(rq.
.TP 3n
\(bu
\fB\-\-port=\fR\fB\fIport_num\fR\fR
.sp
The TCP/IP port number to use for the connection.
.TP 3n
\(bu
\fB\-\-socket=\fR\fB\fIpath\fR\fR
.sp
For connections to
localhost, the Unix socket file to use.
.TP 3n
\(bu
\fB\-\-type=\fR\fB\fIengine_name\fR\fR
.sp
Specify the storage engine that the tables should be converted to use. The default is
MyISAM
if this option is not given.
.TP 3n
\(bu
\fB\-\-user=\fR\fB\fIuser_name\fR\fR
.sp
The MySQL user name to use when connecting to the server.
.TP 3n
\(bu
\fB\-\-verbose\fR
.sp
Verbose mode. Print more information about what the program does.
.TP 3n
\(bu
\fB\-\-version\fR
.sp
Display version information and exit.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_find_rows\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_FIND_ROWS\\F" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_find_rows \- extract SQL statements from files
.SH "SYNOPSIS"
.HP 42
\fBmysql_find_rows [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fIfile_name\fR\fR\fB ...]\fR
.SH "DESCRIPTION"
.PP
\fBmysql_find_rows\fR
reads files containing SQL statements and extracts statements that match a given regular expression or that contain
USE \fIdb_name\fR
or
SET
statements. The utility was written for use with update log files (as used prior to MySQL 5.0) and as such expects statements to be terminated with semicolon (;) characters. It may be useful with other files that contain SQL statements as long as statements are terminated with semicolons.
.PP
Invoke
\fBmysql_find_rows\fR
like this:
.sp
.RS 3n
.nf
shell> \fBmysql_find_rows [\fR\fB\fIoptions\fR\fR\fB] [\fR\fB\fIfile_name\fR\fR\fB ...]\fR
.fi
.RE
.PP
Each
\fIfile_name\fR
argument should be the name of file containing SQL statements. If no file names are given,
\fBmysql_find_rows\fR
reads the standard input.
.PP
Examples:
.sp
.RS 3n
.nf
mysql_find_rows \-\-regexp=problem_table \-\-rows=20 < update.log
mysql_find_rows \-\-regexp=problem_table update\-log.1 update\-log.2
.fi
.RE
.PP
\fBmysql_find_rows\fR
supports the following options:
.TP 3n
\(bu
\fB\-\-help\fR,
\fB\-\-Information\fR
.sp
Display a help message and exit.
.TP 3n
\(bu
\fB\-\-regexp=\fR\fB\fIpattern\fR\fR
.sp
Display queries that match the pattern.
.TP 3n
\(bu
\fB\-\-rows=\fR\fB\fIN\fR\fR
.sp
Quit after displaying
\fIN\fR
queries.
.TP 3n
\(bu
\fB\-\-skip\-use\-db\fR
.sp
Do not include
USE \fIdb_name\fR
statements in the output.
.TP 3n
\(bu
\fB\-\-start_row=\fR\fB\fIN\fR\fR
.sp
Start output from this row.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_fix_extensions\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_FIX_EXTENSI" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_fix_extensions \- normalize table file name extensions
.SH "SYNOPSIS"
.HP 30
\fBmysql_fix_extensions \fR\fB\fIdata_dir\fR\fR
.SH "DESCRIPTION"
.PP
\fBmysql_fix_extensions\fR
converts the extensions for
MyISAM
(or
ISAM) table files to their canonical forms. It looks for files with extensions matching any lettercase variant of
\fI.frm\fR,
\fI.myd\fR,
\fI.myi\fR,
\fI.isd\fR, and
\fI.ism\fR
and renames them to have extensions of
\fI.frm\fR,
\fI.MYD\fR,
\fI.MYI\fR,
\fI.ISD\fR, and
\fI.ISM\fR, respectively. This can be useful after transferring the files from a system with case\-insensitive file names (such as Windows) to a system with case\-sensitive file names.
.PP
Invoke
\fBmysql_fix_extensions\fR
like this, where
\fIdata_dir\fR
is the path name to the MySQL data directory.
.sp
.RS 3n
.nf
shell> \fBmysql_fix_extensions \fR\fB\fIdata_dir\fR\fR
.fi
.RE
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_fix_privilege_tables\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_FIX_PRIVILE" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_fix_privilege_tables \- upgrade MySQL system tables
.SH "SYNOPSIS"
.HP 52
\fBmysql_fix_privilege_tables \-\-password=\fR\fB\fIroot_password\fR\fR
.SH "DESCRIPTION"
.PP
Some releases of MySQL introduce changes to the structure of the system tables in the
mysql
database to add new privileges or support new features. When you update to a new version of MySQL, you should update your system tables as well to make sure that their structure is up to date. Otherwise, there might be capabilities that you cannot take advantage of. First, make a backup of your
mysql
database, and then use the following procedure.
.sp
.it 1 an-trap
.nr an-no-space-flag 1
.nr an-break-flag 1
.br
\fBNote\fR
.PP
As of MySQL 5.1.7,
\fBmysql_fix_privilege_tables\fR
is superseded by
\fBmysql_upgrade\fR, which should be used instead. See
\fBmysql_upgrade\fR(1).
.PP
On Unix or Unix\-like systems, update the system tables by running the
\fBmysql_fix_privilege_tables\fR
script:
.sp
.RS 3n
.nf
shell> \fBmysql_fix_privilege_tables\fR
.fi
.RE
.PP
You must run this script while the server is running. It attempts to connect to the server running on the local host as
root. If your
root
account requires a password, indicate the password on the command line like this:
.sp
.RS 3n
.nf
shell> \fBmysql_fix_privilege_tables \-\-password=\fR\fB\fIroot_password\fR\fR
.fi
.RE
.PP
The
\fBmysql_fix_privilege_tables\fR
script performs any actions necessary to convert your system tables to the current format. You might see some
Duplicate column name
warnings as it runs; you can ignore them.
.PP
After running the script, stop the server and restart it so that it uses any changes that were made to the system tables.
.PP
On Windows systems, MySQL distributions include a
\fImysql_fix_privilege_tables.sql\fR
SQL script that you can run using the
\fBmysql\fR
client. For example, if your MySQL installation is located at
\fIC:\\Program Files\\MySQL\\MySQL Server 5.1\fR, the commands look like this:
.sp
.RS 3n
.nf
C:\\> \fBcd "C:\\Program Files\\MySQL\\MySQL Server 5.1"\fR
C:\\> \fBbin\\mysql \-u root \-p mysql\fR
mysql> \fBSOURCE share/mysql_fix_privilege_tables.sql\fR
.fi
.RE
.sp
.it 1 an-trap
.nr an-no-space-flag 1
.nr an-break-flag 1
.br
\fBNote\fR
.PP
Prior to version 5.1.17, this script is found in the
\fIscripts\fR
directory.
.PP
The
\fBmysql\fR
command will prompt you for the
root
password; enter it when prompted.
.PP
If your installation is located in some other directory, adjust the path names appropriately.
.PP
As with the Unix procedure, you might see some
Duplicate column name
warnings as
\fBmysql\fR
processes the statements in the
\fImysql_fix_privilege_tables.sql\fR
script; you can ignore them.
.PP
After running the script, stop the server and restart it.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
.\" Title: \fBmysql_install_db\fR
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: 03/31/2009
.\" Manual: MySQL Database System
.\" Source: MySQL 5.1
.\"
.TH "\fBMYSQL_INSTALL_DB\\" "1" "03/31/2009" "MySQL 5.1" "MySQL Database System"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
mysql_install_db \- initialize MySQL data directory
.SH "SYNOPSIS"
.HP 27
\fBmysql_install_db [\fR\fB\fIoptions\fR\fR\fB]\fR
.SH "DESCRIPTION"
.PP
\fBmysql_install_db\fR
initializes the MySQL data directory and creates the system tables that it contains, if they do not exist.
.PP
To invoke
\fBmysql_install_db\fR, use the following syntax:
.sp
.RS 3n
.nf
shell> \fBmysql_install_db [\fR\fB\fIoptions\fR\fR\fB]\fR
.fi
.RE
.PP
Because the MySQL server,
\fBmysqld\fR, needs to access the data directory when it runs later, you should either run
\fBmysql_install_db\fR
from the same account that will be used for running
\fBmysqld\fR
or run it as
root
and use the
\fB\-\-user\fR
option to indicate the user name that
\fBmysqld\fR
will run as. It might be necessary to specify other options such as
\fB\-\-basedir\fR
or
\fB\-\-datadir\fR
if
\fBmysql_install_db\fR
does not use the correct locations for the installation directory or data directory. For example:
.sp
.RS 3n
.nf
shell> \fBbin/mysql_install_db \-\-user=mysql \\\fR
\fB\-\-basedir=/opt/mysql/mysql \\\fR
\fB\-\-datadir=/opt/mysql/mysql/data\fR
.fi
.RE
.PP
\fBmysql_install_db\fR
needs to invoke
\fBmysqld\fR
with the
\fB\-\-bootstrap\fR
and
\fB\-\-skip\-grant\-tables\fR
options (see
Section\ 2.10.2, \(lqTypical \fBconfigure\fR Options\(rq). If MySQL was configured with the
\fB\-\-disable\-grant\-options\fR
option,
\fB\-\-bootstrap\fR
and
\fB\-\-skip\-grant\-tables\fR
will be disabled. To handle this, set the
MYSQLD_BOOTSTRAP
environment variable to the full path name of a server that has all options enabled.
\fBmysql_install_db\fR
will use that server.
.PP
\fBmysql_install_db\fR
supports the options in the following list. It also reads option files and supports the options for processing them described at
Section\ 4.2.3.2.1, \(lqCommand\-Line Options that Affect Option\-File Handling\(rq.
.TP 3n
\(bu
\fB\-\-basedir=\fR\fB\fIpath\fR\fR
.sp
The path to the MySQL installation directory.
.TP 3n
\(bu
\fB\-\-force\fR
.sp
Causes
\fBmysql_install_db\fR
to run even if DNS does not work. In that case, grant table entries that normally use host names will use IP addresses.
.TP 3n
\(bu
\fB\-\-datadir=\fR\fB\fIpath\fR\fR,
\fB\-\-ldata=\fR\fB\fIpath\fR\fR
.sp
The path to the MySQL data directory.
.TP 3n
\(bu
\fB\-\-rpm\fR
.sp
For internal use. This option is used by RPM files during the MySQL installation process.
.TP 3n
\(bu
\fB\-\-skip\-name\-resolve\fR
.sp
Use IP addresses rather than host names when creating grant table entries. This option can be useful if your DNS does not work.
.TP 3n
\(bu
\fB\-\-srcdir=\fR\fB\fIpath\fR\fR
.sp
For internal use. The directory under which
\fBmysql_install_db\fR
looks for support files such as the error message file and the file for populating the help tables. This option was added in MySQL 5.1.14.
.TP 3n
\(bu
\fB\-\-user=\fR\fB\fIuser_name\fR\fR
.sp
The login user name to use for running
\fBmysqld\fR. Files and directories created by
\fBmysqld\fR
will be owned by this user. You must be
root
to use this option. By default,
\fBmysqld\fR
runs using your current login name and files and directories that it creates will be owned by you.
.TP 3n
\(bu
\fB\-\-verbose\fR
.sp
Verbose mode. Print more information about what the program does.
.TP 3n
\(bu
\fB\-\-windows\fR
.sp
For internal use. This option is used for creating Windows distributions.
.SH "COPYRIGHT"
.PP
Copyright 2007\-2008 MySQL AB, 2009 Sun Microsystems, Inc.
.PP
This documentation is free software; you can redistribute it and/or modify it only under the terms of the GNU General Public License as published by the Free Software Foundation; version 2 of the License.
.PP
This documentation is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
.PP
You should have received a copy of the GNU General Public License along with the program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110\-1301 USA or see http://www.gnu.org/licenses/.
.SH "SEE ALSO"
For more information, please refer to the MySQL Reference Manual,
which may already be installed locally and which is also available
online at http://dev.mysql.com/doc/.
.SH AUTHOR
MySQL AB (http://www.mysql.com/).
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
.so man1/mysqltest.1
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment