403Webshell
Server IP : 104.21.38.3  /  Your IP : 172.70.208.163
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/src/mysql-test/suite/rpl/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/server/mysql/src/mysql-test/suite/rpl/t/rpl_apply_binlog_with_same_server_id.test
# ==== Purpose ====
#
# This test verifies that when replicate_same_server_id=1 then there should
# not be any conflicts applying binary log files as relay log files in a
# server that has the same server id as the server id in the files.
#
# ==== Implementation ====
#
# 1) Supress a warning.
# 2) Initialize source datadir path.
# 3) Stop the server.
# 4) Rename the already executed and saved binary logs to relay
#    logs and copy them to the data dir.
# 5) Restart the server.
# 6) start replica.
# 7) Wait for replica to finish.
# 8) Cleanup.
#
# ==== References ====
#
# Bug#27492990 PARALLEL REPLICATION ALWAYS FAILS WITH SPECIFIC WORKLOAD FROM SYSBENCH
#

# This test requires row format binlogging.
--source include/have_binlog_format_row.inc
--source include/have_gtid.inc
--source include/only_mts_slave_parallel_workers.inc
--source include/only_mts_slave_parallel_type_logical_clock.inc

# 1) Supress a warning.
call mtr.add_suppression("using --replicate-same-server-id in conjunction with --log-replica-updates would lead to infinite loops in this server.");

# 2) Initialize source data dir path.
--let $master_datadir= `select @@datadir`

# 3) Stop Server.
--source include/shutdown_mysqld.inc

# 4) Rename the already executed and saved binary logs to relay logs and copy them to data dir.
--copy_file $MYSQL_TEST_DIR/std_data/replicated-bin.000001 $master_datadir/replicate-relay-bin.000001
--copy_file $MYSQL_TEST_DIR/std_data/replicated-bin.000002 $master_datadir/replicate-relay-bin.000002
--copy_file $MYSQL_TEST_DIR/std_data/replicated-bin.index $master_datadir/replicate-relay-bin.index

# 5) Restart the server.
--let $restart_parameters="restart: --replicate-same-server-id=1 --server_id=1 --relay-log=replicate-relay-bin"
--source include/start_mysqld.inc

# 6) Start replica.
SET GLOBAL RELAY_LOG_PURGE=OFF;
CHANGE MASTER TO RELAY_LOG_FILE='replicate-relay-bin.000001', RELAY_LOG_POS=1, MASTER_HOST='dummy';
START SLAVE SQL_THREAD;

# 7) Wait for replica to finish.
--let $show_statement= SHOW PROCESSLIST
--let $field= State
--let $condition= = 'Slave has read all relay log; waiting for more updates'
--source include/wait_show_condition.inc

# 8) Cleanup.
SET GLOBAL RELAY_LOG_PURGE=ON;
STOP SLAVE SQL_THREAD;
CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root';

Youez - 2016 - github.com/yon3zu
LinuXploit