| 1 |
include/master-slave.inc |
| 2 |
Warnings: |
| 3 |
Note #### Sending passwords in plain text without SSL/TLS is extremely insecure. |
| 4 |
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. |
| 5 |
[connection master] |
| 6 |
[connection slave] |
| 7 |
CALL mtr.add_suppression('Duplicate entry .* for key'); |
| 8 |
CALL mtr.add_suppression('A replica with the same server_uuid/server_id as this replica has connected to the source'); |
| 9 |
CALL mtr.add_suppression('The replica coordinator and worker threads are stopped'); |
| 10 |
CHANGE REPLICATION SOURCE TO SOURCE_USER='root', SOURCE_HOST='127.0.0.1', SOURCE_PORT=MASTER_PORT FOR CHANNEL 'ch1'; |
| 11 |
Warnings: |
| 12 |
Note 1759 Sending passwords in plain text without SSL/TLS is extremely insecure. |
| 13 |
Note 1760 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. |
| 14 |
# |
| 15 |
# Start and stop slave |
| 16 |
# |
| 17 |
include/stop_slave.inc [FOR CHANNEL ''] |
| 18 |
include/start_slave.inc [FOR CHANNEL 'ch1'] |
| 19 |
include/check_slave_is_running.inc [FOR CHANNEL 'ch1'] |
| 20 |
include/check_slave_no_error.inc [FOR CHANNEL 'ch1'] |
| 21 |
include/stop_slave.inc [FOR CHANNEL 'ch1'] |
| 22 |
include/start_slave.inc [FOR CHANNEL ''] |
| 23 |
include/check_slave_is_running.inc [FOR CHANNEL ''] |
| 24 |
include/check_slave_no_error.inc [FOR CHANNEL ''] |
| 25 |
include/stop_slave_io.inc [FOR CHANNEL ''] |
| 26 |
include/stop_slave_sql.inc [FOR CHANNEL ''] |
| 27 |
include/start_slave_io.inc [FOR CHANNEL 'ch1'] |
| 28 |
include/start_slave_sql.inc [FOR CHANNEL 'ch1'] |
| 29 |
include/stop_slave_io.inc [FOR CHANNEL 'ch1'] |
| 30 |
include/stop_slave_sql.inc [FOR CHANNEL 'ch1'] |
| 31 |
include/start_slave_io.inc [FOR CHANNEL ''] |
| 32 |
include/start_slave_sql.inc [FOR CHANNEL ''] |
| 33 |
# |
| 34 |
# Sync slave |
| 35 |
# |
| 36 |
[connection master] |
| 37 |
CREATE TABLE t1 (c1 INT PRIMARY KEY) ENGINE=InnoDB; |
| 38 |
include/sync_slave_io_with_master.inc [FOR CHANNEL ''] |
| 39 |
include/sync_slave_sql_with_io.inc [FOR CHANNEL ''] |
| 40 |
[connection master] |
| 41 |
INSERT INTO t1 VALUES (1); |
| 42 |
include/sync_slave_sql_with_master.inc [FOR CHANNEL ''] |
| 43 |
include/stop_slave_io.inc [FOR CHANNEL ''] |
| 44 |
include/start_slave.inc [FOR CHANNEL 'ch1'] |
| 45 |
[connection master] |
| 46 |
INSERT INTO t1 VALUES (2); |
| 47 |
include/sync_slave_io_with_master.inc [FOR CHANNEL 'ch1'] |
| 48 |
include/sync_slave_sql_with_io.inc [FOR CHANNEL 'ch1'] |
| 49 |
[connection master] |
| 50 |
INSERT INTO t1 VALUES (3); |
| 51 |
include/sync_slave_sql_with_master.inc [FOR CHANNEL 'ch1'] |
| 52 |
include/stop_slave.inc [FOR CHANNEL 'ch1'] |
| 53 |
include/start_slave.inc [FOR CHANNEL ''] |
| 54 |
# |
| 55 |
# Show relaylog events |
| 56 |
# |
| 57 |
include/show_relaylog_events.inc [FOR CHANNEL ''] |
| 58 |
Log_name Pos Event_type Server_id End_log_pos Info |
| 59 |
slave-relay-bin.000004 # Rotate # # master-bin.000001;pos=POS |
| 60 |
slave-relay-bin.000004 # Format_desc # # SERVER_VERSION, BINLOG_VERSION |
| 61 |
slave-relay-bin.000004 # Rotate # # master-bin.000001;pos=POS |
| 62 |
slave-relay-bin.000004 # Query # # use `test`; CREATE TABLE t1 (c1 INT PRIMARY KEY) ENGINE=InnoDB |
| 63 |
slave-relay-bin.000004 # Query # # BEGIN |
| 64 |
slave-relay-bin.000004 # Query # # use `test`; INSERT INTO t1 VALUES (1) |
| 65 |
slave-relay-bin.000004 # Xid # # COMMIT /* XID */ |
| 66 |
slave-relay-bin.000004 # Rotate # # slave-relay-bin.000005;pos=POS |
| 67 |
include/show_relaylog_events.inc [FOR CHANNEL 'ch1'] |
| 68 |
Log_name Pos Event_type Server_id End_log_pos Info |
| 69 |
slave-relay-bin-ch1.000003 # Rotate # # master-bin.000001;pos=POS |
| 70 |
slave-relay-bin-ch1.000003 # Format_desc # # SERVER_VERSION, BINLOG_VERSION |
| 71 |
# |
| 72 |
# Wait for error and skip |
| 73 |
# |
| 74 |
INSERT INTO t1 VALUES (4); |
| 75 |
[connection master] |
| 76 |
INSERT INTO t1 VALUES (4); |
| 77 |
[connection slave] |
| 78 |
include/wait_for_slave_sql_error.inc [errno=1062 FOR CHANNEL ''] |
| 79 |
include/start_slave_io.inc [FOR CHANNEL 'ch1'] |
| 80 |
include/wait_for_slave_io_error.inc [errno=13114 FOR CHANNEL ''] |
| 81 |
START SLAVE SQL_THREAD FOR CHANNEL 'ch1'; |
| 82 |
Warnings: |
| 83 |
Warning 1287 'START SLAVE' is deprecated and will be removed in a future release. Please use START REPLICA instead |
| 84 |
include/wait_for_slave_sql_error.inc [errno=1062 FOR CHANNEL 'ch1'] |
| 85 |
include/start_slave_io.inc [FOR CHANNEL ''] |
| 86 |
include/wait_for_slave_io_error.inc [errno=13114 FOR CHANNEL 'ch1'] |
| 87 |
DELETE FROM t1 WHERE c1 = 4; |
| 88 |
include/start_slave_sql.inc [FOR CHANNEL ''] |
| 89 |
include/include/rpl_skip_to_end_of_relay_log.inc [FOR CHANNEL 'ch1'] |
| 90 |
include/stop_slave.inc [FOR CHANNEL 'ch1'] |
| 91 |
# |
| 92 |
# Cleanup |
| 93 |
# |
| 94 |
RESET SLAVE ALL FOR CHANNEL 'ch1'; |
| 95 |
Warnings: |
| 96 |
Warning 1287 'RESET SLAVE' is deprecated and will be removed in a future release. Please use RESET REPLICA instead |
| 97 |
[connection master] |
| 98 |
DROP TABLE t1; |
| 99 |
include/rpl_end.inc |