STOP SLAVE
Syntax
STOP SLAVE ["connection_name"] [thread_type [, thread_type] ... ] STOP ALL SLAVES [thread_type [, thread_type]] thread_type: IO_THREAD | SQL_THREAD
Description
Stops the slave threads. STOP SLAVE
requires the SUPER
privilege.
Like START SLAVE
, this statement may be used with the IO_THREAD
and
SQL_THREAD
options to name the thread or threads to be stopped. In almost all cases, one never need to use the thread_type
options.
STOP SLAVE
waits until any current replication event group affecting
one or more non-transactional tables has finished executing (if there
is any such replication group), or until the user issues a KILL QUERY
or KILL CONNECTION
statement.
STOP ALL SLAVES
MariaDB starting with 10.0
STOP ALL SLAVES
stops all your running slaves. It will give you a note
for every stopped connection. You can check the notes with SHOW WARNINGS
.
connection_name
MariaDB starting with 10.0
The connection_name
option was added as part of multi-source replication added in MariaDB 10.0
If there is only one nameless master, or the default master (as specified by the default_master_connection
system variable) is intended, connection_name
can be omitted. If provided, the STOP SLAVE
statement will apply to the specified master. connection_name
is case-insensitive.
See Also
- CHANGE MASTER TO is used to create and change connections.
- START SLAVE is used to start a predefined connection.
- RESET SLAVE is used to reset parameters for a connection and also to permanently delete a master connection.