mysqld_multi
— Manage Multiple MySQL Servers
250
The path to the MySQL installation directory.
•
--datadir=path
[250]
The path to the MySQL data directory.
•
--pid-file=file_name
[250]
The path name of the file in which the server should write its process ID.
•
--service-startup-timeout=file_name
[250]
How long in seconds to wait for confirmation of server startup. If the server does not start within this
time,
mysql.server
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.0.40. Before that, a value of 900 is always used.
•
--use-mysqld_safe
[250]
Use
mysqld_safe
to start the server. This is the default. This option was added in MySQL 5.0.4.
•
--use-manager
[250]
Use Instance Manager to start the server. This option was added in MySQL 5.0.4.
•
--user=user_name
[250]
The login user name to use for running
mysqld
. This option was added in MySQL 5.0.4.
4.3.4.
mysqld_multi
— Manage Multiple MySQL Servers
mysqld_multi
is designed to manage several
mysqld
processes that listen for connections
on different Unix socket files and TCP/IP ports. It can start or stop servers, or report their current
status. The MySQL Instance Manager is an alternative means of managing multiple servers (see
Section 4.6.10, “
mysqlmanager
— The MySQL Instance Manager”
).
mysqld_multi
searches for groups named
[mysqldN]
in
my.cnf
(or in the file named by the
--
config-file
[251]
option).
N
can be any positive integer. This number is referred to in the following
discussion as the option group number, or
GNR
. Group numbers distinguish option groups from one
another and are used as arguments to
mysqld_multi
to specify which servers you want to start,
stop, or obtain a status report for. Options listed in these groups are the same that you would use in the
[mysqld]
group used for starting
mysqld
. (See, for example,
Section 2.18.1.2, “Starting and Stopping
MySQL Automatically”
.) However, when using multiple servers, it is necessary that each one use its
own value for options such as the Unix socket file and TCP/IP port number. For more information on
which options must be unique per server in a multiple-server environment, see
Section 5.3, “Running
Multiple MySQL Instances on One Machine”
.
To invoke
mysqld_multi
, use the following syntax:
shell>
mysqld_multi [options] {start|stop|report} [GNR[,GNR] ...]
start
,
stop
, and
report
indicate which operation to perform. You can perform the designated
operation for a single server or multiple servers, depending on the
GNR
list that follows the option name.
If there is no list,
mysqld_multi
performs the operation for all servers in the option file.
Each
GNR
value represents an option group number or range of group numbers. The value should be
the number at the end of the group name in the option file. For example, the
GNR
for a group named
[mysqld17]
is
17
. To specify a range of numbers, separate the first and last numbers by a dash. The
GNR
value
10-13
represents groups
[mysqld10]
through
[mysqld13]
. Multiple groups or group
ranges can be specified on the command line, separated by commas. There must be no whitespace
characters (spaces or tabs) in the
GNR
list; anything after a whitespace character is ignored.
Summary of Contents for 5.0
Page 1: ...MySQL 5 0 Reference Manual ...
Page 18: ...xviii ...
Page 60: ...40 ...
Page 396: ...376 ...
Page 578: ...558 ...
Page 636: ...616 ...
Page 844: ...824 ...
Page 1234: ...1214 ...
Page 1427: ...MySQL Proxy Scripting 1407 ...
Page 1734: ...1714 ...
Page 1752: ...1732 ...
Page 1783: ...Configuring Connector ODBC 1763 ...
Page 1793: ...Connector ODBC Examples 1773 ...
Page 1839: ...Connector Net Installation 1819 2 You must choose the type of installation to perform ...
Page 2850: ...2830 ...
Page 2854: ...2834 ...
Page 2928: ...2908 ...
Page 3000: ...2980 ...
Page 3122: ...3102 ...
Page 3126: ...3106 ...
Page 3174: ...3154 ...
Page 3232: ...3212 ...