MASTER mysqld --no-defaults --console --log-warnings=0 --innodb-lock-wait-timeout=1 --skip-grant-tables --skip-name-resolve --innodb-flush-log-at-trx-commit=0 --sync-binlog=0 --log-bin --binlog-format=statement --port=3306 --socket=sock --server-id=1 --tmpdir=. --plugin-load=semisync_master.dll --loose-rpl_semi_sync_master_enabled=1 --loose-rpl_semi_sync_master_timeout=1000000 --max-binlog-size=4k SLAVE mysqld --no-defaults --console --skip-grant-tables --skip-slave-start --skip-name-resolve --innodb-file-per-table --port=3307 --server-id=5 --innodb-flush-log-at-trx-commit=0 --tmpdir=. --socket=sock --plugin-load=semisync_slave.dll --loose-rpl_semi_sync_slave_enabled=1 mysql> show processlist; +----+------+------+------+-------------+------+-------------------------------------------------------+------------------+ | Id | User | Host | db | Command | Time | State | Info | +----+------+------+------+-------------+------+-------------------------------------------------------+------------------+ | 7 | root | | NULL | Binlog Dump | 200 | Finished reading one binlog; switching to next binlog | NULL | | 11 | root | | test | Sleep | 2 | | NULL | | 12 | root | | test | Query | 192 | Waiting for semi-sync ACK from slave | commit | | 13 | root | | test | Query | 192 | init | commit | | 14 | root | | test | Query | 192 | init | commit | | 15 | root | | test | Query | 190 | init | commit | | 16 | root | | test | Query | 190 | init | commit | | 17 | root | | test | Query | 190 | init | commit | | 18 | root | | test | Query | 190 | init | commit | | 19 | root | | test | Query | 189 | init | commit | | 20 | root | | test | Query | 189 | init | commit | | 21 | root | | test | Query | 189 | init | commit | | 22 | root | | test | Query | 189 | init | commit | | 23 | root | | test | Query | 189 | init | commit | | 24 | root | | test | Query | 189 | init | commit | | 25 | root | | test | Query | 189 | init | commit | | 26 | root | | test | Query | 189 | init | commit | | 27 | root | | test | Killed | 161 | init | show master logs | | 30 | root | | test | Query | 0 | init | show processlist | +----+------+------+------+-------------+------+-------------------------------------------------------+------------------+ 19 rows in set (0.00 sec) My testcase output: D:\svn_gypsy\win32\debug>gypsy --queryfile=semi.sql --threads=15 --duration=900000 [INFO] 03:48:10 [0344] 4308 - 32-bit version of Gypsy for MySQL [INFO] 03:48:10 [0354] 4308 - using 1 hosts [INFO] 03:48:10 [0468] 4308 - client library version: 5.1.57 [ALWAYS] 03:48:10 [0481] 4308 - server 00: '5.6.9-rc-log', host: '127.0.0.1 via TCP/IP', SSL: 'NULL', protocol: 10, charset: utf8 [INFO] 03:48:10 [0555] 4308 - read 8 valid queries from query file [INFO] 03:48:10 [0627] 4308 - spawning data generation thread [INFO] 03:48:10 [0690] 4656 - creating new char data for the first time [INFO] 03:48:10 [0708] 4656 - refreshing char data [INFO] 03:48:10 [0715] 4656 - char data has been generated, char_increment=10 [INFO] 03:48:10 [0662] 4308 - now running for 900000 seconds. [INFO] 03:48:10 [0668] 4308 - running initialization queries [INFO] 03:48:10 [1544] 5224 - thread 0 connecting to host 0 [INFO] 03:48:10 [1574] 5224 - thread 0 has 1 alive hosts connected [WARN] 03:48:10 [2573] 5224 - thread[00] didn't complete entire query file. Might need longer --duration= [INFO] 03:48:10 [0690] 4308 - about to create all 'populate' scripts from I_S [INFO] 03:48:10 [0734] 4308 - spawning database stats thread [ALWAYS] 03:48:10 [0745] 4308 - spawning 15 new thread(s) [INFO] 03:48:10 [1161] 8844 - writing server status variables to 'report_8844_host_00.txt' [INFO] 03:48:10 [1544] 6872 - thread 0 connecting to host 0 [INFO] 03:48:10 [1574] 6872 - thread 0 has 1 alive hosts connected [INFO] 03:48:10 [1544] 8568 - thread 1 connecting to host 0 [INFO] 03:48:10 [1574] 8568 - thread 1 has 1 alive hosts connected [ERROR] 03:48:10 [2676] 6872 - query failed (1213) - 40001 (Deadlock found when trying to get lock; try restarting transaction): insert ignore into t1 values (-21037,'9097') [...] [INFO] 03:48:10 [1544] 10180 - thread 2 connecting to host 0 [INFO] 03:48:10 [1574] 10180 - thread 2 has 1 alive hosts connected [INFO] 03:48:10 [1544] 8580 - thread 3 connecting to host 0 [INFO] 03:48:10 [1574] 8580 - thread 3 has 1 alive hosts connected [INFO] 03:48:10 [1544] 9392 - thread 4 connecting to host 0 [INFO] 03:48:10 [1574] 9392 - thread 4 has 1 alive hosts connected [INFO] 03:48:10 [1544] 9104 - thread 5 connecting to host 0 [INFO] 03:48:10 [1574] 9104 - thread 5 has 1 alive hosts connected [INFO] 03:48:10 [1544] 8380 - thread 6 connecting to host 0 [INFO] 03:48:10 [1574] 8380 - thread 6 has 1 alive hosts connected [INFO] 03:48:11 [1544] 9656 - thread 7 connecting to host 0 [INFO] 03:48:11 [1574] 9656 - thread 7 has 1 alive hosts connected [INFO] 03:48:11 [1544] 2872 - thread 8 connecting to host 0 [INFO] 03:48:11 [1574] 2872 - thread 8 has 1 alive hosts connected [INFO] 03:48:11 [1544] 6624 - thread 9 connecting to host 0 [INFO] 03:48:11 [1574] 6624 - thread 9 has 1 alive hosts connected [INFO] 03:48:11 [1544] 2368 - thread 10 connecting to host 0 [INFO] 03:48:11 [1574] 2368 - thread 10 has 1 alive hosts connected [INFO] 03:48:11 [1544] 8032 - thread 11 connecting to host 0 [INFO] 03:48:11 [1574] 8032 - thread 11 has 1 alive hosts connected [INFO] 03:48:11 [1544] 8940 - thread 12 connecting to host 0 [INFO] 03:48:11 [1574] 8940 - thread 12 has 1 alive hosts connected [INFO] 03:48:11 [1544] 5688 - thread 13 connecting to host 0 [INFO] 03:48:11 [1574] 5688 - thread 13 has 1 alive hosts connected [INFO] 03:48:11 [1544] 4552 - thread 14 connecting to host 0 [INFO] 03:48:11 [1574] 4552 - thread 14 has 1 alive hosts connected [INFO] 03:48:11 [0783] 4308 - completed spawning new database worker threads [ERROR] 03:48:12 [2676] 9392 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:12 [2676] 8380 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:12 [2676] 8580 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:12 [2676] 9104 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 2368 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 8032 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 6624 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 9656 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 8940 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 4552 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 2872 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [ERROR] 03:48:13 [2676] 5688 - query failed (1205) - HY000 (Lock wait timeout exceeded; try restarting transaction): update t1 set b='-8945' where a>'24400' limit 5 [...] [INFO] 03:48:22 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (34.666667 QPS). [INFO] 03:48:33 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:48:44 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:48:55 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:49:06 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:49:17 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:49:28 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:49:39 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:49:50 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:01 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:12 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:23 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:34 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:45 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:50:56 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:51:07 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:51:18 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:51:29 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). [INFO] 03:51:40 [0825] 4308 - 15 threads running, 0000416 successful queries. 0000013 failed queries (0.000000 QPS). semi.sql: -------------- i|1|drop table if exists t1 i|1|create table t1(a int primary key,b varchar(10),key(b))engine=innodb; n|1|start transaction n|1|insert ignore into t1 values (?,'?')|smallint,smallint n|1|delete from t1 where b='?'|smallint n|1|update t1 set b='?' where a>'?' limit 5|smallint,smallint n|1|select * from t1 where b='?'|smallint n|1|commit commits are waiting here: ----------------------------- ntdll.dll!ZwWaitForKeyedEvent() + 0xa bytes ntdll.dll!RtlSleepConditionVariableCS() + 0xd4 bytes kernel32.dll!SleepConditionVariableCS() + 0x28 bytes mysqld.exe!pthread_cond_timedwait(pthread_cond_t * cond=0x0000000000000000, _RTL_CRITICAL_SECTION * mutex=0x00000000122d0b10, timespec * abstime=0x0000000015d4c580) Line 313 + 0xf bytes C mysqld.exe!Stage_manager::enroll_for(Stage_manager::StageID stage=FLUSH_STAGE, THD * thd=0x0000000140147670, st_mysql_mutex * stage_mutex=0x00000000122d0b10) Line 1337 C++ mysqld.exe!MYSQL_BIN_LOG::change_stage(THD * thd=0x000000001241b780, Stage_manager::StageID stage=303576480, THD * queue=0x00000000121835a0, st_mysql_mutex * leave_mutex=0x0000000000000000, st_mysql_mutex * enter_mutex=0x0000000140147678) Line 6100 + 0x1a bytes C++ mysqld.exe!MYSQL_BIN_LOG::ordered_commit(THD * thd=0x0000000000000001, bool all=false, bool skip_commit=true) Line 6289 C++ mysqld.exe!MYSQL_BIN_LOG::commit(THD * thd=0x0000000015d4d801, bool all=true) Line 5863 + 0x12 bytes C++ mysqld.exe!ha_commit_trans(THD * thd=0x0000000000000000, bool all=true) Line 1420 + 0x18 bytes C++ mysqld.exe!trans_commit(THD * thd=0x0000000000000000) Line 220 C++ mysqld.exe!mysql_execute_command(THD * thd=0x00000000122d27e0) Line 4168 + 0x8 bytes C++ mysqld.exe!mysql_parse(THD * thd=0x0000000000000003, char * rawbuf=0x00000000123207c1, unsigned int length=366276464, Parser_state * parser_state=0x00000000122d0b10) Line 6122 C++ mysqld.exe!dispatch_command(enum_server_command command=COM_SLEEP, THD * thd=0x0000000000000000, char * packet=0x00000000122d0b10, unsigned int packet_length=301066688) Line 1315 C++ mysqld.exe!do_command(THD * thd=0x000000000000002d) Line 1042 C++ mysqld.exe!do_handle_one_connection(THD * thd_arg=0x00000000122d0b10) Line 969 + 0xa bytes C++ mysqld.exe!handle_one_connection(void * arg=0x00000000122d0b10) Line 887 C++ mysqld.exe!pfs_spawn_thread(void * arg=0x0000000011f1e9c0) Line 1856 C++ mysqld.exe!pthread_start(void * p=0x0000000012324800) Line 63 C > mysqld.exe!_callthreadstartex() Line 314 + 0xd bytes C mysqld.exe!_threadstartex(void * ptd=0x0000000000000000) Line 292 + 0x5 bytes C kernel32.dll!BaseThreadInitThunk() + 0xd bytes ntdll.dll!ZwWaitForKeyedEvent() + 0xa bytes ntdll.dll!RtlSleepConditionVariableCS() + 0xd4 bytes kernel32.dll!SleepConditionVariableCS() + 0x28 bytes mysqld.exe!pthread_cond_timedwait(pthread_cond_t * cond=0x0000000010e3c4d0, _RTL_CRITICAL_SECTION * mutex=0x0000000010e3c4d0, timespec * abstime=0x00000001401476b2) Line 313 + 0xf bytes C semisync_master.dll!ReplSemiSyncMaster::cond_timewait(timespec * wait_time=0x00000001401476b2) Line 470 C++ semisync_master.dll!ReplSemiSyncMaster::commitTrx(const char * trx_wait_binlog_name=0x0000000006bb9990, unsigned __int64 trx_wait_binlog_pos=112991784) Line 714 C++ mysqld.exe!Trans_delegate::after_commit(THD * thd=0x0000000011f0a480, bool all=true) Line 233 + 0xa0 bytes C++ mysqld.exe!ha_commit_low(THD * thd=0x0000000011f0a480, bool all=true) Line 1507 C++ mysqld.exe!MYSQL_BIN_LOG::process_commit_stage_queue(THD * thd=0x0000000140147b48, THD * first=0x0000000000000000, int flush_error=300983424) Line 6034 + 0x8 bytes C++ mysqld.exe!MYSQL_BIN_LOG::ordered_commit(THD * thd=0x0000000000001230, bool all=true, bool skip_commit=false) Line 6361 C++ mysqld.exe!MYSQL_BIN_LOG::commit(THD * thd=0x0000000010e3d901, bool all=true) Line 5863 + 0x12 bytes C++ mysqld.exe!ha_commit_trans(THD * thd=0x0000000000000000, bool all=true) Line 1420 + 0x18 bytes C++ mysqld.exe!trans_commit(THD * thd=0x0000000000000000) Line 220 C++ mysqld.exe!mysql_execute_command(THD * thd=0x0000000011f0c150) Line 4168 + 0x8 bytes C++ > mysqld.exe!mysql_parse(THD * thd=0x0000000000000003, char * rawbuf=0x0000000006bb26a1, unsigned int length=283373680, Parser_state * parser_state=0x0000000011f0a480) Line 6122 C++ mysqld.exe!dispatch_command(enum_server_command command=COM_SLEEP, THD * thd=0x0000000000000000, char * packet=0x0000000006c08c00, unsigned int packet_length=300486752) Line 1315 C++ mysqld.exe!do_command(THD * thd=0x0000000000000001) Line 1042 C++ mysqld.exe!do_handle_one_connection(THD * thd_arg=0x0000000011f0a480) Line 969 + 0xa bytes C++ mysqld.exe!handle_one_connection(void * arg=0x0000000006c08c00) Line 887 C++ mysqld.exe!pfs_spawn_thread(void * arg=0x0000000011e91060) Line 1856 C++ mysqld.exe!pthread_start(void * p=0x0000000011edf950) Line 63 C mysqld.exe!_callthreadstartex() Line 314 + 0xd bytes C mysqld.exe!_threadstartex(void * ptd=0x0000000000000000) Line 292 + 0x5 bytes C kernel32.dll!BaseThreadInitThunk() + 0xd bytes ntdll.dll!RtlUserThreadStart() + 0x21 bytes binlog send thread: ---------- ntdll.dll!ZwWaitForSingleObject() + 0xa bytes ntdll.dll!RtlpWaitOnCriticalSection() + 0xe8 bytes ntdll.dll!RtlEnterCriticalSection() - 0x4be5 bytes > mysqld.exe!Log_event::read_log_event(st_io_cache * file=0x0000000000000000, String * packet=0x000000001363da40, st_mysql_mutex * log_lock=0x0000000000000002, unsigned char checksum_alg_arg='') Line 1188 C++ mysqld.exe!mysql_binlog_send(THD * thd=0x0000000000000019, char * log_ident=0x0000000011fb5b20, unsigned __int64 pos=5364555344, const Gtid_set * slave_gtid_executed=0x0000000011fb8ceb) Line 1082 + 0x1b bytes C++ mysqld.exe!com_binlog_dump(THD * thd=0x0000000011fb8ce1, char * packet=0x000000001363ecc0, unsigned int packet_length=301685536) Line 697 C++ mysqld.exe!dispatch_command(enum_server_command command=COM_SLEEP, THD * thd=0x0000000000000000, char * packet=0x0000000011fb5b20, unsigned int packet_length=300489248) Line 1506 + 0xe bytes C++ mysqld.exe!do_command(THD * thd=0x0000000000000006) Line 1042 C++ mysqld.exe!do_handle_one_connection(THD * thd_arg=0x0000000011fb5b20) Line 969 + 0xa bytes C++ mysqld.exe!handle_one_connection(void * arg=0x0000000011fb5b20) Line 887 C++ mysqld.exe!pfs_spawn_thread(void * arg=0x0000000011e91a20) Line 1856 C++ mysqld.exe!pthread_start(void * p=0x0000000011f103a0) Line 63 C mysqld.exe!_callthreadstartex() Line 314 + 0xd bytes C mysqld.exe!_threadstartex(void * ptd=0x0000000000000000) Line 292 + 0x5 bytes C kernel32.dll!BaseThreadInitThunk() + 0xd bytes ntdll.dll!RtlUserThreadStart() + 0x21 bytes rotating binlog: ----------- ntdll.dll!ZwWaitForSingleObject() + 0xa bytes ntdll.dll!RtlpWaitOnCriticalSection() + 0xe8 bytes ntdll.dll!RtlEnterCriticalSection() - 0x4be5 bytes > mysqld.exe!MYSQL_BIN_LOG::new_file_impl(bool need_lock_log=true, Format_description_log_event * extra_description_event=0x0000000000000000) Line 4315 C++ mysqld.exe!MYSQL_BIN_LOG::rotate(bool force_rotate=true, bool * check_purge=0x0000000011eeddd0) Line 4841 + 0xc bytes C++ mysqld.exe!MYSQL_BIN_LOG::ordered_commit(THD * thd=0x0000000000001068, bool all=false, bool skip_commit=false) Line 6398 C++ mysqld.exe!MYSQL_BIN_LOG::commit(THD * thd=0x00000000133ad301, bool all=true) Line 5863 + 0x12 bytes C++ mysqld.exe!ha_commit_trans(THD * thd=0x0000000000000000, bool all=true) Line 1420 + 0x18 bytes C++ mysqld.exe!trans_commit(THD * thd=0x0000000000000000) Line 220 C++ mysqld.exe!mysql_execute_command(THD * thd=0x0000000011eefaa0) Line 4168 + 0x8 bytes C++ mysqld.exe!mysql_parse(THD * thd=0x0000000000000003, char * rawbuf=0x0000000011ef0f91, unsigned int length=322628288, Parser_state * parser_state=0x0000000011eeddd0) Line 6122 C++ mysqld.exe!dispatch_command(enum_server_command command=COM_SLEEP, THD * thd=0x0000000000000000, char * packet=0x0000000011ee6510, unsigned int packet_length=300487904) Line 1315 C++ mysqld.exe!do_command(THD * thd=0x0000000000000003) Line 1042 C++ mysqld.exe!do_handle_one_connection(THD * thd_arg=0x0000000011eeddd0) Line 969 + 0xa bytes C++ mysqld.exe!handle_one_connection(void * arg=0x0000000011ee6510) Line 887 C++ mysqld.exe!pfs_spawn_thread(void * arg=0x0000000011e914e0) Line 1856 C++ mysqld.exe!pthread_start(void * p=0x0000000011eedb00) Line 63 C mysqld.exe!_callthreadstartex() Line 314 + 0xd bytes C mysqld.exe!_threadstartex(void * ptd=0x0000000000000000) Line 292 + 0x5 bytes C kernel32.dll!BaseThreadInitThunk() + 0xd bytes ntdll.dll!RtlUserThreadStart() + 0x21 bytes