| 1 |
include/group_replication.inc [rpl_server_count=3] |
| 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 server1] |
| 6 |
|
| 7 |
# 1. Bootstrap M1 with lower patch version. |
| 8 |
# Start GR on M2 with higher patch version. |
| 9 |
|
| 10 |
[connection server1] |
| 11 |
SET @debug1_save= @@GLOBAL.DEBUG; |
| 12 |
SET @@GLOBAL.DEBUG= 'd,group_replication_compatibility_lower_patch_version'; |
| 13 |
include/start_and_bootstrap_group_replication.inc |
| 14 |
[connection server2] |
| 15 |
SET @debug2_save= @@GLOBAL.DEBUG; |
| 16 |
SET @@GLOBAL.DEBUG= 'd,group_replication_compatibility_higher_patch_version'; |
| 17 |
SET SESSION sql_log_bin=0; |
| 18 |
call mtr.add_suppression("Member version is read compatible with the group."); |
| 19 |
SET SESSION sql_log_bin=1; |
| 20 |
include/start_group_replication.inc |
| 21 |
include/assert.inc [The super_read_only mode should be 1 on server2.] |
| 22 |
|
| 23 |
# 2. Block slave thread of applier on M1. |
| 24 |
|
| 25 |
[connection server1] |
| 26 |
SET @@GLOBAL.DEBUG='+d,block_applier_updates'; |
| 27 |
|
| 28 |
# 3. Send Start GR on M3 with base version. |
| 29 |
|
| 30 |
[connection server3] |
| 31 |
SET SESSION sql_log_bin=0; |
| 32 |
call mtr.add_suppression("Member version is read compatible with the group."); |
| 33 |
SET SESSION sql_log_bin=1; |
| 34 |
SET GLOBAL group_replication_group_name= "GROUP_REPLICATION_GROUP_NAME"; |
| 35 |
START GROUP_REPLICATION;; |
| 36 |
|
| 37 |
# 4. Stop GR on M1 so M3 has no member to recover from. |
| 38 |
# Set allow_local_lower_version_join on M3 so M3 uses M2 as donor. |
| 39 |
|
| 40 |
[connection server1] |
| 41 |
SET DEBUG_SYNC = "now WAIT_FOR applier_read_blocked"; |
| 42 |
SET @@GLOBAL.DEBUG='-d,block_applier_updates'; |
| 43 |
SET @@GLOBAL.DEBUG='+d,force_sql_thread_error'; |
| 44 |
SET DEBUG_SYNC = "now SIGNAL resume_applier_read"; |
| 45 |
include/gr_wait_for_member_state.inc |
| 46 |
SET @@GLOBAL.DEBUG='-d,force_sql_thread_error'; |
| 47 |
include/stop_group_replication.inc |
| 48 |
[connection server_3] |
| 49 |
SET @@GLOBAL.group_replication_allow_local_lower_version_join=1; |
| 50 |
[connection server3] |
| 51 |
|
| 52 |
# 5. Verify M3 is ONLINE and writable since its new lowest version. |
| 53 |
|
| 54 |
include/assert.inc [The super_read_only mode should be 0 on server3.] |
| 55 |
[connection server2] |
| 56 |
include/assert.inc [The super_read_only mode should be 1 on server2.] |
| 57 |
|
| 58 |
# 6. Cleanup. |
| 59 |
|
| 60 |
SET @@GLOBAL.DEBUG= @debug2_save; |
| 61 |
include/stop_group_replication.inc |
| 62 |
[connection server1] |
| 63 |
SET @@GLOBAL.DEBUG= @debug1_save; |
| 64 |
SET DEBUG_SYNC= 'RESET'; |
| 65 |
SET SESSION sql_log_bin = 0; |
| 66 |
call mtr.add_suppression("Replica SQL for channel 'group_replication_applier': Relay log read failure: Could not parse relay log event entry.*"); |
| 67 |
call mtr.add_suppression("The applier thread execution was aborted. Unable to process more transactions, this member will now leave the group."); |
| 68 |
call mtr.add_suppression("Fatal error during execution on the Applier process of Group Replication. The server will now leave the group."); |
| 69 |
call mtr.add_suppression("The server was automatically set into read only mode after an error was detected."); |
| 70 |
call mtr.add_suppression("Skipping leave operation: concurrent attempt to leave the group is on-going."); |
| 71 |
SET SESSION sql_log_bin = 1; |
| 72 |
[connection server3] |
| 73 |
SET @@GLOBAL.group_replication_allow_local_lower_version_join= 0; |
| 74 |
include/group_replication_end.inc |