config root man

Current Path : /home/usr.opt/mysql57/mysql-test/suite/group_replication/r/

FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64
Upload File :
Current File : /home/usr.opt/mysql57/mysql-test/suite/group_replication/r/gr_recovery_completion_mode.result

include/group_replication.inc
Warnings:
Note	####	Sending passwords in plain text without SSL/TLS is extremely insecure.
Note	####	Storing MySQL user name or password information in the master info repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START SLAVE; see the 'START SLAVE Syntax' in the MySQL Manual for more information.
[connection server1]
######################################################################
# Phase 1:
# Recovery only waits for the certification of all cached transactions
######################################################################
#
# Create t1 and t2 on both servers
# Start group replication on server 1 after inserting data on t1
#
server1
SET SESSION sql_log_bin=0;
CREATE TABLE t1 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB;
CREATE TABLE t2 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB;
SET SESSION sql_log_bin=1;
include/start_and_bootstrap_group_replication.inc
INSERT INTO t1 VALUES (1);
server2
SET SESSION sql_log_bin=0;
CREATE TABLE t1 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB;
CREATE TABLE t2 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB;
SET SESSION sql_log_bin=1;
#
# Lock table t1 and table t2 on server 2
# Table t1: Blocks first phase of recovery
# Table t2: Blocks second phase of recovery
#
SET @configured_rec_policy= @@GLOBAL.group_replication_recovery_complete_at;
SET GLOBAL group_replication_recovery_complete_at= "transactions_certified";
server_2 (server2)
LOCK TABLE t1 READ;
slave (server2)
LOCK TABLE t2 READ;
#
# Start group replication on server 2 and check it is stuck on recovery
#
server2
include/start_group_replication.inc
#
# Insert some transaction on server 1 that will be cached on server 2
#
server1
SELECT WAIT_FOR_EXECUTED_GTID_SET('08033a70-3560-11e5-a2cb-0800200c9a66:3');
WAIT_FOR_EXECUTED_GTID_SET('08033a70-3560-11e5-a2cb-0800200c9a66:3')
0
INSERT INTO t2 VALUES (1);
#
# UnLock table t1: First phase of recovery can carry on.
# Member 1 is online as it only waits for certification of cached data
#
server_2 (server2)
UNLOCK TABLES;
server2
include/gr_wait_for_member_state.inc
#
# UnLock table t2: Second phase of recovery can carry on.
# The data should be there.
#
slave (server2)
UNLOCK TABLES;
#
# Phase 1 cleanup
# Remove the data from the tables and stop group replication on server 2
#
server1
TRUNCATE TABLE t1;
TRUNCATE TABLE t2;
include/rpl_sync.inc
server2
include/stop_group_replication.inc
######################################################################
# Phase 2:
# Recovery waits for the execution of all executed transactions
######################################################################
#
# Start group replication on server 1 after inserting data on t1
#
server1
INSERT INTO t1 VALUES (1);
#
# Change recovery policy on server 2 to wait for transaction execution.
#
server2
SET GLOBAL group_replication_recovery_complete_at= "transactions_applied";
#
# Lock table t1 and table t2 on server 2
# Table t1: Blocks first phase of recovery
# Table t2: Blocks second phase of recovery
#
server_2 (server2)
LOCK TABLE t1 READ;
slave (server2)
LOCK TABLE t2 READ;
#
# Start group replication on server 2 and check it is stuck on recovery
#
server2
include/start_group_replication.inc
#
# Insert some transaction on server 1 that will be cached on server 2
#
server1
INSERT INTO t2 VALUES (1);
#
# Wait for the transactions to be cached on server 2
#
server2
#
# UnLock table t1: First phase of recovery can carry on.
# Member 2 is still recovering as it can't apply cached data
#
server_2 (server2)
UNLOCK TABLES;
server2
include/assert.inc [The value of member_state should be recovering]
#
# UnLock table t2: Second phase of recovery can carry on.
# The data should be there and the member should now be online.
#
slave (server2)
UNLOCK TABLES;
include/gr_wait_for_member_state.inc
#
# Test cleanup
#
server2
DROP TABLE t1;
DROP TABLE t2;
SET GLOBAL group_replication_recovery_complete_at= @configured_rec_policy;
include/group_replication_end.inc

Man Man