Changing wsrep_slave_threads causes future connections to hang
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
MySQL patches by Codership | Status tracked in 5.6 | |||||
5.6 |
Fix Committed
|
Undecided
|
Seppo Jaakola |
Bug Description
Changing the wsrep_slave_threads variable back to the default of 1 causes the SQL connection to hang on subsequent DDL, with the thread blocked as follows:
Thread 5 (Thread 0x7f48dc3ce700 (LWP 34185)):
#0 0x0000003f2e00bcf0 in pthread_
#1 0x00000000005a78ef in inline_
#2 block_until_
#3 one_thread_
#4 0x00000000006e19b8 in do_handle_
#5 0x00000000006e1c09 in handle_
#6 0x0000003f2e007f35 in start_thread () from /lib64/
#7 0x0000003f2d8f4c3d in clone () from /lib64/libc.so.6
Test case:
--source include/
--source include/
CREATE TABLE t1 (f1 INTEGER AUTO_INCREMENT PRIMARY KEY, f2 INTEGER) Engine=InnoDB;
--connection node_2
SET GLOBAL wsrep_slave_threads = 4;
SET GLOBAL wsrep_slave_threads = 1;
DROP TABLE t1;
affects: | galera → codership-mysql |
What happens is that, at the end of the test, mysqltest attempts to connect to node_2 in order to check for warnings in the server log. This connection hangs with:
#0 0x0000003f2d8ea7b0 in __poll_nocancel () from /lib64/libc.so.6 git/codership- mysql/vio/ viosocket. c:771 0x7fb1b5ae1010, host=0x4bdec0 "localhost", user=<optimized out>, passwd=0xb27620 "", db=0x0, port=13003, unix_socket= 0xb288d1 "/home/ philips/ git/codership- mysql/mysql- test/var/ tmp/mysqld. 2.sock" , client_ flag=2147549184 ) at /home/philips/ git/codership- mysql/sql- common/ client. c:3612 mysql@entry= 0x7fb1b5ae1010, name=0xb27bd0 "default", host=0xb2891f "localhost", user=0xb288bf "root", pass=0xb27620 "", db=0x0, port=13003, sock=0xb288d1 "/home/ philips/ git/codership- mysql/mysql- test/var/ tmp/mysqld. 2.sock" ) at /home/philips/ git/codership- mysql/client/ mysqltest. cc:5319 e3c8) at /home/philips/ git/codership- mysql/client/ mysqltest. cc:8748
#1 0x00000000004493a3 in vio_io_wait (vio=<optimized out>, event=<optimized out>, timeout=120000) at /home/philips/
#2 0x0000000000422a53 in mysql_real_connect (mysql=
#3 0x00000000004102d4 in safe_connect (mysql=
#4 0x000000000040a5ae in main (argc=4, argv=0x7fffd582