403Webshell
Server IP : 172.67.216.182  /  Your IP : 162.158.108.169
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/ndb_rpl/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/server/mysql/src/mysql-test/suite/ndb_rpl/t/ndb_rpl_init_rep_status.test
# The include statement below is a temp one for tests that are yet to
#be ported to run with InnoDB,
#but needs to be kept for tests that would need MyISAM in future.
--source include/force_myisam_default.inc

--source include/have_ndb.inc
--source include/have_binlog_format_mixed_or_row.inc
--source suite/ndb_rpl/ndb_master-slave.inc

# Test Slave initialisation of Ndb_slave_max_replicated_epoch status var

--connection slave
reset master;
stop slave;

--connection master
--echo Generate something in the Masters Binlog
use test;
create table t1 (a int primary key, b int) engine=ndb;

insert into t1 values (1,1);

--connection slave
--echo Initial state
select * from mysql.ndb_apply_status;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc
select @slave_server_id:= @@server_id;

--echo Default, no data, max replicated epoch will be 0.
reset slave;
start slave;
--connection master
--sync_slave_with_master
--connection slave
--replace_column 3 # 4 # 5 #
select server_id from mysql.ndb_apply_status order by server_id;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc

--echo Default, load of own serverid from ndb_apply_status, should be 111
drop table test.t1;
stop slave;
reset slave;
insert into mysql.ndb_apply_status values (@slave_server_id, 111, 'Fictional log', 222, 333);
start slave;
--connection master
--sync_slave_with_master
--connection slave
--replace_column 3 # 4 # 5 #
select server_id from mysql.ndb_apply_status order by server_id;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc

drop table test.t1;

--echo Check that reset slave resets Ndb_slave_max_replicated_epoch
stop slave;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc
reset slave;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc

--echo Multiple-channel, load highest of configured serverids, should be 222
set @other_local_server_id=@slave_server_id+1;
set @other_remote_server_id=@slave_server_id+2;
insert into mysql.ndb_apply_status values (@slave_server_id, 111, 'Fictional log', 222, 333);
insert into mysql.ndb_apply_status values (@other_local_server_id, 222, 'Fictional log', 222, 333);
insert into mysql.ndb_apply_status values (@other_remote_server_id, 444, 'Fictional log', 222, 333);

let $local_server_ids = `select @other_local_server_id`;

--eval CHANGE MASTER TO IGNORE_SERVER_IDS=($local_server_ids);
start slave;
--connection master
--sync_slave_with_master
--connection slave
--replace_column 3 # 4 # 5 #
select server_id from mysql.ndb_apply_status order by server_id;
--source suite/ndb_rpl/t/show_slave_max_replicated_epoch.inc

# Clean up
stop slave;
CHANGE MASTER TO IGNORE_SERVER_IDS= ();
start slave;
--connection master
drop table test.t1;
sync_slave_with_master;

--source include/rpl_end.inc


Youez - 2016 - github.com/yon3zu
LinuXploit