Server IP : 104.21.38.3 / Your IP : 162.158.189.190 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /www/server/mysql/mysql-test/suite/group_replication/t/ |
Upload File : |
################################################################################ # This test intends to stress Group Replication startup # by starting and stopping without waiting for the member to come online # as it is done classically in all other tests. # # Test: # 0. The test requires three servers: M1, M2 and M3. # 1. Bootstrap start a group on M1. Start GR on M2. # 2. Create some transactions to ensure that recovery works fine. # 3. Wait for all servers to be in sync. # 4. Stress M3 by joining, leaving and joining again without waiting. # 5. Start and assert check that M3 has recovered properly. Validate value of # gtid_executed and data in the table. # 6. Clean up. ################################################################################ --source include/big_test.inc --source include/not_valgrind.inc --let $group_replication_group_name= 57006580-b202-11e4-ab27-0800200c9a66 --source ../inc/have_group_replication_plugin.inc --let $rpl_skip_group_replication_start= 1 --let $rpl_server_count= 3 --let $rpl_gtid_utils= 1 --source ../inc/group_replication.inc --echo # --echo # Setup a new group --echo # --connection server1 --echo server1 --source ../inc/start_and_bootstrap_group_replication.inc --connection server2 --echo server2 --source include/start_group_replication.inc --echo # --echo # Create some transactions here to ensure that Recovery works fine in --echo # the end --echo # CREATE TABLE t1 (c1 INT NOT NULL PRIMARY KEY) ENGINE=InnoDB; INSERT INTO t1 VALUES (1); INSERT INTO t1 VALUES (2); INSERT INTO t1 VALUES (3); --echo # --echo # Wait for all servers to be in sync --echo # --source include/rpl_sync.inc --connection server3 --echo server3 --echo # --echo # Stress server 3 by joining, leaving and joining again without waiting --echo # --eval SET GLOBAL group_replication_group_name= "$group_replication_group_name" --let $number_of_reps= 5 while($number_of_reps > 0) { start group_replication; stop group_replication; --dec $number_of_reps } --echo # --echo # Start and assert that server 3 has recovered properly --echo # --source include/start_group_replication.inc --let $assert_text= GTID_EXECUTED must contain all group transactions --let $assert_cond= GTID_IS_EQUAL(@@GLOBAL.GTID_EXECUTED, "$group_replication_group_name:1-12") --source include/assert.inc --echo # --echo # Check that values are present --echo # SELECT * FROM t1; --echo # --echo # Cleanup and exit --echo # --connection server1 --echo server1 DROP TABLE t1; --source ../inc/group_replication_end.inc