Debian Codegraph @

mysql-test/suite/rpl/r/rpl_log_info_repository_persistence_require_row.result

raw
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
7 # 0. Create a user to use as a privilege_checks_user
8 # Create some test auxiliary include files to avoid step repetition.
9 [connection slave]
10 CREATE USER 'replication_applier'@'localhost' IDENTIFIED BY 'password';
11 GRANT REPLICATION_APPLIER ON * . * TO 'replication_applier'@'localhost';
12 FLUSH PRIVILEGES;
13
14 # 1.1. Set REQUIRE_ROW_FORMAT to 1
15 # Check the performance_schema table and file repository are correct
16 STOP SLAVE;
17 Warnings:
18 Warning 1287 'STOP SLAVE' is deprecated and will be removed in a future release. Please use STOP REPLICA instead
19 CHANGE REPLICATION SOURCE TO SOURCE_HOST="localhost", REQUIRE_ROW_FORMAT = 1;
20 include/assert.inc [Check that mysql.slave_relay_log_info does not have any entry]
21 include/assert.inc [REQUIRE_ROW_FORMAT enabled for default channel "" in performance_schema.replication_applier_configuration]
22 include/assert_grep.inc [In the file the field is set to 1]
23
24 # 1.2. Set REQUIRE_ROW_FORMAT to 0
25 # Check the performance_schema table and file repository are correct
26 CHANGE REPLICATION SOURCE TO REQUIRE_ROW_FORMAT = 0;
27 include/assert.inc [Check that mysql.slave_relay_log_info does not have any entry]
28 include/assert.inc [REQUIRE_ROW_FORMAT disabled for default channel "" in performance_schema.replication_applier_configuration]
29
30 # 2.1 Upgrade the server while using File repositories
31 # Start the server using a file repository that has no privileged user
32 # REQUIRE_ROW_FORMAT must be 0
33 include/rpl_stop_server.inc [server_number=2]
34 include/rpl_start_server.inc [server_number=2 parameters: --skip_replica_start]
35 include/assert.inc [Check that mysql.slave_relay_log_info does not have any entry]
36 include/assert.inc [REQUIRE_ROW_FORMAT disabled for default channel "" in performance_schema.replication_applier_configuration]
37
38 # 2.2 Upgrade the server while using File repositories
39 # Start the server using a file repository that has a privileged user
40 # REQUIRE_ROW_FORMAT must be 0
41 include/rpl_stop_server.inc [server_number=2]
42 include/rpl_start_server.inc [server_number=2 parameters: --skip_replica_start]
43 include/assert.inc [Check that mysql.slave_relay_log_info does not have any entry]
44 include/assert.inc [REQUIRE_ROW_FORMAT disabled for default channel "" in performance_schema.replication_applier_configuration]
45 # Reset the repository to default values
46 CHANGE REPLICATION SOURCE TO PRIVILEGE_CHECKS_USER=NULL, REQUIRE_ROW_FORMAT = 0;
47 include/assert.inc [Check that mysql.slave_relay_log_info does not have any entry]
48 include/assert.inc [REQUIRE_ROW_FORMAT disabled for default channel "" in performance_schema.replication_applier_configuration]
49
50 # 3.1 Upgrade the server to Table repositories from File repositories
51 # Start the server using a file repository that has no privileged user
52 # REQUIRE_ROW_FORMAT must be 0
53 ALTER TABLE mysql.slave_relay_log_info DROP COLUMN Require_row_format;
54 include/rpl_stop_server.inc [server_number=2]
55 include/rpl_start_server.inc [server_number=2 parameters: --skip_replica_start --relay-log-info-repository=TABLE --upgrade=FORCE]
56 include/assert.inc [Check that mysql.slave_relay_log_info has an entry with REQUIRE_ROW_FORMAT set to 0]
57 include/assert.inc [Check entry for default channel "" in performance_schema.replication_applier_configuration]
58
59 # 3.2 Upgrade the server to Table repositories from File repositories
60 # Start the server using a file repository that has a privileged user
61 # REQUIRE_ROW_FORMAT must be 0
62 include/rpl_restart_server.inc [server_number=2 parameters: --relay-log-info-repository=FILE]
63 ALTER TABLE mysql.slave_relay_log_info DROP COLUMN Require_row_format;
64 include/rpl_stop_server.inc [server_number=2]
65 include/rpl_start_server.inc [server_number=2 parameters: --skip_replica_start --relay-log-info-repository=TABLE --upgrade=FORCE]
66 include/assert.inc [Check that mysql.slave_relay_log_info has an entry with REQUIRE_ROW_FORMAT set to 0]
67 include/assert.inc [Check entry for default channel "" in performance_schema.replication_applier_configuration]
68
69 # 4.1 Upgrade the server while using Table repositories
70 # Have 3 channels:
71 # 1. A channel with no privileged user (ch1)
72 # 2. A group_replication channel (group_replication_recovery)
73 # 3. A channel with a privileged user (default channel)
74 # REQUIRE_ROW_FORMAT must be 0 for 1) and 3). It must be 1 for 2)
75 include/rpl_set_gtid_mode.inc
76 CHANGE REPLICATION SOURCE TO SOURCE_HOST="localhost", SOURCE_PORT=12 FOR CHANNEL "ch1" ;
77 CHANGE REPLICATION SOURCE TO SOURCE_USER="root" FOR CHANNEL "group_replication_recovery";
78 CHANGE REPLICATION SOURCE TO SOURCE_HOST="localhost", SOURCE_PORT=12, PRIVILEGE_CHECKS_USER = 'replication_applier'@'localhost' FOR CHANNEL "";
79 ALTER TABLE mysql.slave_relay_log_info DROP COLUMN Require_row_format;
80 UPDATE mysql.slave_relay_log_info SET Number_of_lines = 10;
81 include/rpl_restart_server.inc [server_number=2 parameters: --skip_replica_start --relay-log-info-repository=TABLE --upgrade=FORCE]
82 include/assert.inc [Check the number of channels with enabled REQUIRE_ROW_FORMAT]
83 include/assert.inc [Check the number of channels with disabled REQUIRE_ROW_FORMAT]
84 include/assert.inc [Check that mysql.slave_relay_log_info has an entry with REQUIRE_ROW_FORMAT set to 0]
85 include/assert.inc [Check that mysql.slave_relay_log_info has an entry with REQUIRE_ROW_FORMAT set to 1]
86 include/assert.inc [Check that mysql.slave_relay_log_info has an entry with REQUIRE_ROW_FORMAT set to 0]
87
88 # 5. Cleanup
89 DROP USER 'replication_applier'@'localhost';
90 RESET SLAVE ALL FOR CHANNEL "ch1";
91 Warnings:
92 Warning 1287 'RESET SLAVE' is deprecated and will be removed in a future release. Please use RESET REPLICA instead
93 RESET SLAVE ALL FOR CHANNEL "group_replication_recovery";
94 Warnings:
95 Warning 1287 'RESET SLAVE' is deprecated and will be removed in a future release. Please use RESET REPLICA instead
96 include/rpl_set_gtid_mode.inc
97 include/rpl_end.inc
98 Warnings:
99 Note 3084 Replication thread(s) for channel '' are already stopped.