Bug #79865 | semi-sync can't run normally when many connections | ||
---|---|---|---|
Submitted: | 7 Jan 2016 3:34 | Modified: | 13 Dec 2016 13:49 |
Reporter: | steven cai | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Replication | Severity: | S1 (Critical) |
Version: | 5.7.10, 5.7.12 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | semi-sync select listener FD_SET |
[7 Jan 2016 3:34]
steven cai
[13 Jun 2016 12:51]
MySQL Verification Team
Another test case to reproduce this problem. I can reproduce it on CentOS 6, bue cannot repoduce it on CentOS 7. (0) Confirm open files settion grater than 1024. (esp.centos6) (1) Prepare a mysql sandbox environment & MySQL 5.7.x generic tarball. (2) Make Master:Slave replication environment with MySQL sandbox command. shell> make_replication_sandbox 5.7.13 (3) make semi-replicatioin setting with sandbox command; ./use_all "INSTALL PLUGIN rpl_semi_sync_master SONAME 'semisync_master.so'; INSTALL PLUGIN rpl_semi_sync_slave SONAME 'semisync_slave.so'; SET GLOBAL rpl_semi_sync_master_enabled = 1; SET GLOBAL rpl_semi_sync_slave_enabled = 1;" (4) re-start slaves; with this command. ./use_all stop slave; ./use_all start slave; (5) enlarge max_connections settiongs. ./use_all set global max_connections=2048; (6) Login to master and create table, schema and keep this connection. ./m test CREATE TABLE t1(i1 int not null primary key, v2 varchar(20)) engine = innodb; create database mysqlslap; (7) make 'slap' script by copying 'use' script of mysql sandbox cp ./use ./slap (8) Change two line of 'slap' as belows. [ -z "$MYSQL_EDITOR" ] && MYSQL_EDITOR="$BASEDIR/bin/mysqlslap" $MYSQL_EDITOR --defaults-file=$MY_CNF $MYCLIENT_OPTIONS "$@" --query="SELECT sleep(180);" --concurrency=1600 --iterations=1 (9) stop slaves ./use_all stop slave (10) start slaves with 10-sec delay. sleep 10;./use_all start slave (11) before stat slaves (within 10-sec) run 'slap' script. ./slap (12) during slap keep 1600-connection, run insert command on (6) connection. insert into t1 values(1,'a'); (13) the problem will occurr in CentOS6 environment.
[14 Jun 2016 5:12]
MySQL Verification Team
Hello Chuck cai, Thank you for the report and test case. Thanks, Umesh
[20 Jun 2016 6:30]
MySQL Verification Team
In my test case, inserting row triggers the all semi-sync=OFF ! and didn't occurred on CentOS7 with the same procedure.
[5 Jul 2016 9:24]
MySQL Verification Team
Bug #82059 marked as duplicate of this
[26 Sep 2016 6:58]
Libing Song
Bug#82207 is a dup of this
[27 Sep 2016 5:56]
Daniël van Eeden
Bug #83013 marked as a duplicate of this
[13 Dec 2016 13:49]
Erlend Dahl
[9 Dec 2016 7:57] David Moss Thank you for your feedback, this has been fixed in upcoming versions and the following was added to the 5.7.17 and 8.0.1 changelogs: Using semisynchronous replication was not possible with more than 1024 simultaneous connections.