MOON
Server: Apache/2.2.21 (Unix) mod_ssl/2.2.21 OpenSSL/0.9.8e-fips-rhel5 mod_auth_passthrough/2.1 mod_bwlimited/1.4
System: Linux vps.panamaemb.org.sg 3.10.0-1160.80.1.vz7.191.4 #1 SMP Thu Dec 15 20:31:06 MSK 2022 x86_64
User: panama (500)
PHP: 5.2.17
Disabled: NONE
Upload Files
File: //proc/2/cwd/usr/share/mysql-test/extra/rpl_tests/rpl_stm_EE_err2.test
###################################
# Author: JBM
# Date: 2006-01-11
# Purpose: Second test case from
#          rpl_EE_err.test split out
#          from orginal to make the
#          first work with both RBR and SBR
###################################
#REQUIREMENT: An INSERT with a faked duplicate entry error on
#master should be replicated to slave and force the slave to stop
#(since the slave can't cause a faked error to re-occur).
###################################

-- source include/master-slave.inc

connection master;
eval create table t1 (a int, unique(a)) engine=$engine_type;
set sql_log_bin=0;
insert into t1 values(2);
set sql_log_bin=1;

--error ER_DUP_ENTRY
insert into t1 values(1),(2);
drop table t1;

connection slave;
call mtr.add_suppression("Slave SQL.*Query caused different errors on master and slave.*Error on master:.* error code=1062.*Error on slave:.* Error_code: 0");
call mtr.add_suppression("The slave coordinator and worker threads are stopped, possibly leaving data in inconsistent state");

--echo (expect different error codes on master and slave)
# ER_MTS_INCONSISTENT_DATA
--let $slave_sql_errno= 0,1756
# can't print error text. MTS reports a separate error in this case.
# Todo: to fix single-threaded-slave BUG#57287.
--let $show_slave_sql_error= 0
--source include/wait_for_slave_sql_error.inc
drop table t1;
--source include/stop_slave.inc
# Clear error messages.
RESET SLAVE;

# End of 4.1 tests

--let $rpl_only_running_threads= 1
--source include/rpl_end.inc