Server IP : 172.67.216.182 / Your IP : 162.158.189.235 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 : |
################################################################################ # WL#9426: Single Primary Mode in Group Replication # # Validate that the leader will switch the RO mode off when # becoming a primary. # # This is a simple test that sets super read only before we # start the group and thus before the server becomes PRIMARY. # Once it becomes primary, it will automatically switch # super read only off. ################################################################################ --source ../inc/have_group_replication_plugin.inc --let $rpl_skip_group_replication_start= 1 --let $rpl_group_replication_single_primary_mode=1 --source ../inc/group_replication.inc --let $rpl_connection_name= server1 --source include/rpl_connection.inc --let $saved_super_read_only= `SELECT @@GLOBAL.super_read_only` --let $saved_read_only= `SELECT @@GLOBAL.read_only` --let $primary_server_uuid= `SELECT @@server_uuid` # set RO to true SET GLOBAL super_read_only= TRUE; --let $assert_cond= "[SELECT @@GLOBAL.super_read_only]" = 1 --let $assert_text= Assert that server is running in super RO. --source include/assert.inc # lets start the group --source ../inc/start_and_bootstrap_group_replication.inc # wait to be primary --let $group_replication_expected_uuid=$primary_server_uuid --source ../inc/gr_wait_primary_member_uuid.inc # assert that the primary will switch to RW mode. --let $assert_cond= "[SELECT @@GLOBAL.super_read_only]" = 0 --let $assert_text= Assert that PRIMARY switches out of super RO. --source include/assert.inc --source include/stop_group_replication.inc --replace_result $saved_super_read_only SAVED_SUPER_READ_ONLY --eval SET GLOBAL super_read_only= $saved_super_read_only --replace_result $saved_read_only SAVED_READ_ONLY --eval SET GLOBAL read_only= $saved_read_only --source ../inc/group_replication_end.inc