403Webshell
Server IP : 88.99.149.37  /  Your IP : 216.73.216.141
Web Server : nginx/1.31.2
System : Linux server-88-99-149-37 6.12.0-124.56.5.el10_1.x86_64 #1 SMP PREEMPT_DYNAMIC Fri May 15 06:12:08 EDT 2026 x86_64
User : muralimurth ( 1015)
PHP Version : 8.4.23
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/local/mysql/mysql-test/suite/rpl/t/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/local/mysql/mysql-test/suite/rpl/t/rpl_slave_load_remove_tmpfile.test
# ==== Purpose ====
#
# This test verifies if the slave fails gracefully when the temporary 
# file used to load data is removed while it is about to be used. 
# Similar errors are caught if the temporary directory is removed.
#
# ==== Implementation ====
#
# Steps:
#    0 - Set debug variable remove_slave_load_file_before_write. This
#        causes the slave to remove the file.
#    1 - Creates a table and populates it through "LOAD DATA INFILE".
#    2 - Catches error.
#
# ==== References ====
#
# BUG#42861: Assigning invalid directories to --slave-load-tmpdir crashes the slave
# BUG#11872422: rpl_slave_load_remove_tmpfile fails sporadically in pb2

--source include/have_binlog_format_statement.inc
--source include/have_innodb.inc
--source include/have_debug.inc
--source include/not_embedded.inc
--source include/not_var_link.inc
--source include/master-slave.inc

##########################################################################
#                            Loading data
##########################################################################

connection slave;
SET @saved_dbug = @@GLOBAL.debug_dbug;
SET @@global.debug_dbug= '+d,remove_slave_load_file_before_write';

connection master;

create table t1(a int not null auto_increment, b int, primary key(a)) engine=innodb;

start transaction;
  insert into t1(b) values (1);
  insert into t1(b) values (2);
  load data infile '../../std_data/rpl_loaddata.dat' into table t1;
commit;

##########################################################################
#                            Catch Error
##########################################################################
connection slave;

# windows and linux different error numbers here:
# Windows:
#  - Last_Errno     29 (File not found)
# Unix like OS: 
#  - Last_Errno      13 (Can't stat file)
--let $slave_sql_errno= 29, 13
--source include/wait_for_slave_sql_error.inc

##########################################################################
#                             Clean up
##########################################################################
connection master;

drop table t1;

--source include/sync_slave_io_with_master.inc
--source include/stop_slave_io.inc
RESET SLAVE;

drop table t1;

call mtr.add_suppression("Slave: Can't get stat of .*");
call mtr.add_suppression("Slave SQL: Error .Can.t get stat of.* error.* 13");
call mtr.add_suppression("Slave: File.* not found.*");
call mtr.add_suppression("Slave SQL: Error .File.* not found.* error.* 29");
--let $rpl_only_running_threads= 1

SET @@GLOBAL.debug_dbug = @saved_dbug;

--source include/rpl_end.inc


Youez - 2016 - github.com/yon3zu
LinuXploit