Bug #47347 ro-pooling.lua + one read-only backend down + event-thread>1 = high CPU (80%)

Submitted: 16 Sep 2009 3:11 Modified: 9 Jan 2015 10:36
Reporter: Diego Medina Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Proxy: Core Severity:S2 (Serious)
Version:0.8.0 OS:Any
Assigned to: Jan Kneschke CPU Architecture:Any

[16 Sep 2009 3:11] Diego Medina
Description:
Using the ro-pooling.lua lua script, at least  --event-threads=2 and you have one proxy-read-only-backend-addresses pointing to a server that is down. Start several connections through the proxy, after about 14 connections / disconnections, the proxy will get stuck with high CPU usage.

How to repeat:
The least items I had to have are these:

1- Start the proxy like this:

$ ./sbin/mysql-proxy --event-threads=2  --proxy-backend-addresses=127.0.0.1:5132  --proxy-read-only-backend-addresses=127.0.0.1:5131  --proxy-lua-script=./share/doc/mysql-proxy/ro-pooling.lua 

127.0.0.1:5131 does not exists (server down)
2- On another terminal, run this:

$ while [ true ] ; 
   do ./sandboxes/msb_5_1_32/use -P4040 -e "exit";
   let x++ ; echo $x;
   sleep 0.1;
done ;

3- After about run 14-20, the proxy process will start using about 80-90% of the CPU. You can stop the shell script at this point, and the proxy will just sit there, using all that CPU
[18 Sep 2009 14:39] Enterprise Tools JIRA Robot
Diego Medina writes: 
ro-pooling.lua file attached
[18 Sep 2009 14:41] Enterprise Tools JIRA Robot
Diego Medina writes: 
shell script attached.
[21 Sep 2009 15:35] Enterprise Tools JIRA Robot
Jan Kneschke writes: 
Moved to 0.8.1 to get 0.8.0 out with this known bug.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.052 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.