| 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 |
############################################################ |
| 8 |
# 1. Deploy a group in single-primary mode on server1 and |
| 9 |
# server2 |
| 10 |
[connection server1] |
| 11 |
include/start_and_bootstrap_group_replication.inc |
| 12 |
include/gr_assert_primary_member.inc |
| 13 |
|
| 14 |
############################################################ |
| 15 |
# 2. Set autocommit OFF on server2 |
| 16 |
[connection server2] |
| 17 |
include/save_sysvars.inc [ |
| 18 |
"GLOBAL.autocommit" |
| 19 |
] |
| 20 |
SET @@GLOBAL.autocommit= 0; |
| 21 |
|
| 22 |
############################################################ |
| 23 |
# 3. Configure a channel on server2 that replicates from |
| 24 |
# server3 |
| 25 |
CHANGE REPLICATION SOURCE TO SOURCE_HOST='127.0.0.1', SOURCE_USER='root', SOURCE_AUTO_POSITION=1, SOURCE_CONNECTION_AUTO_FAILOVER=0, SOURCE_PORT=SERVER_3_PORT, SOURCE_CONNECT_RETRY=1, SOURCE_RETRY_COUNT=1 FOR CHANNEL 'ch1'; |
| 26 |
Warnings: |
| 27 |
Note 1759 Sending passwords in plain text without SSL/TLS is extremely insecure. |
| 28 |
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. |
| 29 |
|
| 30 |
############################################################ |
| 31 |
# 4. Start group replication on server2 |
| 32 |
include/start_group_replication.inc |
| 33 |
include/gr_assert_secondary_member.inc |
| 34 |
|
| 35 |
############################################################ |
| 36 |
# 5. Configure and start a failover channel on server1 that |
| 37 |
# replicates from server3 |
| 38 |
[connection server1] |
| 39 |
CHANGE REPLICATION SOURCE TO SOURCE_HOST='127.0.0.1', SOURCE_USER='root', SOURCE_AUTO_POSITION=1, SOURCE_CONNECTION_AUTO_FAILOVER=1, SOURCE_PORT=SERVER_3_PORT, SOURCE_CONNECT_RETRY=1, SOURCE_RETRY_COUNT=1 FOR CHANNEL 'ch1'; |
| 40 |
Warnings: |
| 41 |
Note 1759 Sending passwords in plain text without SSL/TLS is extremely insecure. |
| 42 |
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. |
| 43 |
|
| 44 |
############################################################ |
| 45 |
# 6. Reset replica on server2 |
| 46 |
[connection server2] |
| 47 |
RESET REPLICA ALL FOR CHANNEL 'ch1'; |
| 48 |
|
| 49 |
############################################################ |
| 50 |
# 7. Clean up. |
| 51 |
[connection server1] |
| 52 |
RESET REPLICA ALL FOR CHANNEL 'ch1'; |
| 53 |
[connection server2] |
| 54 |
include/stop_group_replication.inc |
| 55 |
include/restore_sysvars.inc |
| 56 |
[connection server1] |
| 57 |
include/stop_group_replication.inc |
| 58 |
include/group_replication_end.inc |