1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126
|
include/group_replication.inc [rpl_server_count=3]
Warnings:
Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
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.
[connection server1]
[connection server1]
include/start_and_bootstrap_group_replication.inc
[connection server2]
include/start_group_replication.inc
include/rpl_gr_wait_for_number_of_members.inc
[connection server3]
SET GLOBAL group_replication_group_name= "GROUP_REPLICATION_DOUBELWRITE";
[connection server1]
ALTER INSTANCE DISABLE INNODB REDO_LOG;
SET sql_log_bin = 0;
call mtr.add_suppression("\\[Warning\\] .*MY-\\d+.* InnoDB redo logging is disabled. All data could be lost in case of a server crash");
SET sql_log_bin = 1;
SHOW GLOBAL STATUS LIKE 'innodb_redo_log_enabled';
Variable_name Value
Innodb_redo_log_enabled OFF
CREATE TABLE test.tab ( c1 int primary key, c2 TEXT);
INSERT INTO test.tab VALUES(1, 'Test wl#5655');
SELECT @@innodb_doublewrite_dir;
@@innodb_doublewrite_dir
NULL
SELECT @@innodb_doublewrite_files;
@@innodb_doublewrite_files
1
SELECT @@innodb_doublewrite_pages;
@@innodb_doublewrite_pages
1
SELECT @@innodb_doublewrite_batch_size;
@@innodb_doublewrite_batch_size
1
include/rpl_sync.inc
[connection server3]
START GROUP_REPLICATION;
[connection server2]
ALTER INSTANCE DISABLE INNODB REDO_LOG;
SET sql_log_bin = 0;
call mtr.add_suppression("\\[Warning\\] .*MY-\\d+.* InnoDB redo logging is disabled. All data could be lost in case of a server crash");
SET sql_log_bin = 1;
SHOW GLOBAL STATUS LIKE 'innodb_redo_log_enabled';
Variable_name Value
Innodb_redo_log_enabled OFF
SELECT @@innodb_doublewrite_dir;
@@innodb_doublewrite_dir
NULL
SELECT @@innodb_doublewrite_files;
@@innodb_doublewrite_files
2
SELECT @@innodb_doublewrite_pages;
@@innodb_doublewrite_pages
2
SELECT @@innodb_doublewrite_batch_size;
@@innodb_doublewrite_batch_size
10
#Validating the records in server3#
[connection server3]
SHOW GLOBAL STATUS LIKE 'innodb_redo_log_enabled';
Variable_name Value
Innodb_redo_log_enabled ON
SELECT * FROM test.tab;
c1 c2
1 Test wl#5655
SELECT @@innodb_doublewrite_dir;
@@innodb_doublewrite_dir
NULL
SELECT @@innodb_doublewrite_files;
@@innodb_doublewrite_files
0
SELECT @@innodb_doublewrite_pages;
@@innodb_doublewrite_pages
0
SELECT @@innodb_doublewrite_batch_size;
@@innodb_doublewrite_batch_size
0
SET GLOBAL innodb_doublewrite_dir=$MYSQL_TMP_DIR/"#DBWL-DIR";
ERROR HY000: Variable 'innodb_doublewrite_dir' is a read only variable
SET GLOBAL innodb_doublewrite_files=1;
ERROR HY000: Variable 'innodb_doublewrite_files' is a read only variable
SET GLOBAL innodb_doublewrite_pages=10;
ERROR HY000: Variable 'innodb_doublewrite_pages' is a read only variable
SET GLOBAL innodb_doublewrite_batch_size=1;
ERROR HY000: Variable 'innodb_doublewrite_batch_size' is a read only variable
include/rpl_sync.inc
#Validating the records in server2
[connection server2]
ALTER INSTANCE ENABLE INNODB REDO_LOG;
SET sql_log_bin = 0;
call mtr.add_suppression("\\[Warning\\] .*MY-\\d+.* InnoDB redo logging is enabled. Data is now safe and can be recovered in case of a server crash.");
SET sql_log_bin = 1;
SHOW GLOBAL STATUS LIKE 'innodb_redo_log_enabled';
Variable_name Value
Innodb_redo_log_enabled ON
SELECT * FROM test.tab;
c1 c2
1 Test wl#5655
SET GLOBAL innodb_doublewrite_dir=$MYSQL_TMP_DIR/"#DBWL-DIR";
ERROR HY000: Variable 'innodb_doublewrite_dir' is a read only variable
SET GLOBAL innodb_doublewrite_files=1;
ERROR HY000: Variable 'innodb_doublewrite_files' is a read only variable
SET GLOBAL innodb_doublewrite_pages=10;
ERROR HY000: Variable 'innodb_doublewrite_pages' is a read only variable
SET GLOBAL innodb_doublewrite_batch_size=1;
ERROR HY000: Variable 'innodb_doublewrite_batch_size' is a read only variable
[connection server1]
ALTER INSTANCE ENABLE INNODB REDO_LOG;
SET sql_log_bin = 0;
call mtr.add_suppression("\\[Warning\\] .*MY-\\d+.* InnoDB redo logging is enabled. Data is now safe and can be recovered in case of a server crash.");
SET sql_log_bin = 1;
SHOW GLOBAL STATUS LIKE 'innodb_redo_log_enabled';
Variable_name Value
Innodb_redo_log_enabled ON
DROP TABLE test.tab;
include/rpl_sync.inc
STOP GROUP_REPLICATION;
include/group_replication_end.inc
|