Debian Codegraph @

mysql-test/suite/group_replication/r/gr_start_gr_with_credentials.result

raw
1 include/group_replication.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 server1]
6
7 # 1. Bootstrap M1. And create new users.
8 [connection server1]
9 include/start_and_bootstrap_group_replication.inc
10 SET SQL_LOG_BIN=0;
11 CREATE USER 'regular_user_p' IDENTIFIED BY 'password';
12 CREATE USER 'regular_user_wp' IDENTIFIED BY '';
13 GRANT REPLICATION SLAVE ON *.* TO "regular_user_p";
14 GRANT REPLICATION SLAVE ON *.* TO "regular_user_wp";
15 SET SQL_LOG_BIN=1;
16
17 # 2. Reset recovery interval to 1 and count to 2 for M2.
18 [connection server2]
19 SET @saved_group_replication_recovery_reconnect_interval = @@GLOBAL.group_replication_recovery_reconnect_interval;
20 SET @saved_gr_recovery_retry_count = @@GLOBAL.group_replication_recovery_retry_count;
21 SET GLOBAL group_replication_recovery_reconnect_interval= 1;
22 SET GLOBAL group_replication_recovery_retry_count= 2;
23 SET GLOBAL group_replication_group_name= "GROUP_REPLICATION_GROUP_NAME";
24
25 # 3. Test START GR works without any option.
26 include/start_group_replication.inc
27 include/stop_group_replication.inc
28
29 # 4. Delete recovery channel and test START GR, it should fail.
30 RESET SLAVE ALL FOR CHANNEL 'group_replication_recovery';
31 Warnings:
32 Warning 1287 'RESET SLAVE' is deprecated and will be removed in a future release. Please use RESET REPLICA instead
33 START GROUP_REPLICATION;
34 include/gr_wait_for_member_state.inc
35 include/stop_group_replication.inc
36
37 # 5. Pass USER as root and test START GR, member should come ONLINE.
38 # START GR without parameter fails, credentials are removed on STOP.
39 START GROUP_REPLICATION USER='root';
40 include/gr_wait_for_member_state.inc
41 include/stop_group_replication.inc
42 START GROUP_REPLICATION;
43 include/gr_wait_for_member_state.inc
44 include/stop_group_replication.inc
45
46 # 6. Test wrong credentials do not connect with master.
47 START GROUP_REPLICATION USER='regular_user_p',PASSWORD='wrong';
48 include/gr_wait_for_member_state.inc
49 include/stop_group_replication.inc
50 START GROUP_REPLICATION USER='regular_user_p';
51 include/gr_wait_for_member_state.inc
52 include/stop_group_replication.inc
53 START GROUP_REPLICATION USER='regular_user_wp' , PASSWORD='password';
54 include/gr_wait_for_member_state.inc
55 include/stop_group_replication.inc
56
57 # 7. Test right credentials in START GR connect with master.
58 START GROUP_REPLICATION USER='regular_user_p' , PASSWORD='password';
59 include/gr_wait_for_member_state.inc
60 include/stop_group_replication.inc
61 START GROUP_REPLICATION USER='regular_user_p' , PASSWORD='password' , DEFAULT_AUTH='wrong_auth';
62 include/gr_wait_for_member_state.inc
63 include/stop_group_replication.inc
64 START GROUP_REPLICATION USER='regular_user_p' , PASSWORD='password' , DEFAULT_AUTH= 'auth_test_plugin';
65 include/gr_wait_for_member_state.inc
66 include/stop_group_replication.inc
67 START GROUP_REPLICATION PASSWORD='password' , USER='regular_user_p', DEFAULT_AUTH='auth_test_plugin';
68 include/gr_wait_for_member_state.inc
69 include/stop_group_replication.inc
70 START GROUP_REPLICATION USER='regular_user_p' , DEFAULT_AUTH= '' , PASSWORD='password';
71 include/gr_wait_for_member_state.inc
72 include/stop_group_replication.inc
73 START GROUP_REPLICATION USER='regular_user_wp';
74 include/gr_wait_for_member_state.inc
75 include/stop_group_replication.inc
76 START GROUP_REPLICATION USER='regular_user_wp' , PASSWORD='';
77 include/gr_wait_for_member_state.inc
78 include/stop_group_replication.inc
79
80 # 8. Cleanup.
81 CHANGE REPLICATION SOURCE TO SOURCE_USER='root' , SOURCE_PASSWORD='' FOR CHANNEL 'group_replication_recovery';
82 Warnings:
83 Note 1759 Sending passwords in plain text without SSL/TLS is extremely insecure.
84 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.
85 SET SESSION sql_log_bin = 0;
86 call mtr.add_suppression("Replica I/O for channel 'group_replication_recovery': Fatal error: Invalid .* username when attempting to connect to the source server.*");
87 call mtr.add_suppression("There was an error when connecting to the donor server. Please check that group_replication_recovery channel credentials and all MEMBER_HOST column values of performance_schema.replication_group_members table are correct and DNS resolvable.");
88 call mtr.add_suppression("For details please check performance_schema.replication_connection_status table and error log messages of Replica I/O for channel group_replication_recovery.");
89 call mtr.add_suppression("Maximum number of retries when trying to connect to a donor reached. Aborting group replication incremental recovery.");
90 call mtr.add_suppression("Fatal error during the incremental recovery process of Group Replication. The server will leave the group.");
91 call mtr.add_suppression("The server was automatically set into read only mode after an error was detected.");
92 call mtr.add_suppression("Skipping leave operation: concurrent attempt to leave the group is on-going.");
93 call mtr.add_suppression("The server was automatically set into read only mode after an error was detected.");
94 SET SESSION sql_log_bin = 1;
95 SET @@GLOBAL.group_replication_recovery_reconnect_interval = @saved_group_replication_recovery_reconnect_interval;
96 SET @@GLOBAL.group_replication_recovery_retry_count = @saved_gr_recovery_retry_count;
97 [connection server1]
98 SET SQL_LOG_BIN=0;
99 DROP USER 'regular_user_p';
100 DROP USER 'regular_user_wp';
101 SET SQL_LOG_BIN=1;
102 include/group_replication_end.inc