1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
|
#
# set up masters server_1 and server_3 with server_2 being a slave.
#.
include/rpl_init.inc [topology=1->2,3->2]
Warnings:
Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
Warnings:
Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
[connection server_2]
call mtr.add_suppression("Replica: Could not start replica for channel");
#
# Verify that Setting sql_replica_skip_counter doesn't effect running
# channels
#
SET GLOBAL sql_replica_skip_counter= 1;
0
include/assert.inc [check that channel_1's Skip_Counter is 0.]
STOP SLAVE SQL_THREAD;
Warnings:
Warning 1287 'STOP SLAVE' is deprecated and will be removed in a future release. Please use STOP REPLICA instead
include/rpl_for_each_connection.inc [include/wait_for_slave_sql_to_stop.inc]
#
# Verify that START SLAVE FOR CHANNEL will copy sql_replica_skip_counter's
# value to the channel and reset sql_replica_skip_counter to 0
#
[connection server_2]
include/stop_slave.inc
include/start_slave.inc [FOR CHANNEL 'channel_1']
1
include/assert.inc [check that channel_1's Skip_Counter is 0.]
include/assert.inc [check that sql_replica_skip_counter is 0]
#
# START SLAVE [SQL_THREAD] will fail when sql_replica_skip_counter is 1
# and there are more than one channels
#
SET GLOBAL sql_replica_skip_counter = 1;
START SLAVE;
ERROR HY000: When sql_replica_skip_counter > 0, it is not allowed to start more than one SQL thread by using 'START REPLICA [SQL_THREAD]'. Value of sql_replica_skip_counter can only be used by one SQL thread at a time. Please use 'START REPLICA [SQL_THREAD] FOR CHANNEL' to start the SQL thread which will use the value of sql_replica_skip_counter.
START SLAVE SQL_THREAD;
ERROR HY000: When sql_replica_skip_counter > 0, it is not allowed to start more than one SQL thread by using 'START REPLICA [SQL_THREAD]'. Value of sql_replica_skip_counter can only be used by one SQL thread at a time. Please use 'START REPLICA [SQL_THREAD] FOR CHANNEL' to start the SQL thread which will use the value of sql_replica_skip_counter.
#
# START SLAVE IO_THREAD should not fail.
#
START SLAVE IO_THREAD;
include/rpl_for_each_connection.inc [include/wait_for_slave_io_to_start.inc]
include/assert.inc [All two IO threads are running after START SLAVE IO_THREAD]
SET GLOBAL sql_replica_skip_counter= 0;
include/rpl_end.inc
RESET REPLICA ALL FOR CHANNEL 'channel_1';
RESET REPLICA ALL FOR CHANNEL 'channel_3';
|