[MXS-1806]  Error in high concurrency when testing maxscale 2.2.4 Created: 2018-04-16  Updated: 2018-05-29  Resolved: 2018-05-29

Status: Closed
Project: MariaDB MaxScale
Component/s: N/A
Affects Version/s: 2.2.4
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: Emma chan Assignee: Timofey Turenko
Resolution: Cannot Reproduce Votes: 0
Labels: None
Environment:

centos 6
sysbench 1.0.13
maxscale:10.86.165.11
mysql master:10.60.230.112
mysql slave:10.60.40.254


Sprint: MXS-SPRINT-56, MXS-SPRINT-57, MXS-SPRINT-58, MXS-SPRINT-59

 Description   

I want to run testing against proxysql and maxscale with sysbench, when I test proxysql,everythin is ok. but when i test maxscale,
sysben keeps reporting an error:

"FATAL: error 2013: Lost connection to MySQL server at 'reading initial communication packet', system error: 104
FATAL: `thread_run' function failed: .../local/share/sysbench/tests/include/oltp_legacy/oltp.lua:49: Failed to connect to the database"

this is the sysbench command:

 /usr/local/bin/sysbench /usr/local/share/sysbench/tests/include/oltp_legacy/oltp.lua --mysql-host=10.86.165.11 --mysql-port=4006 --mysql-user=proxytestuser --mysql-password=123456 --db-driver=mysql --mysql-db=sbtest --oltp-tables-count=10 --oltp-table-size=500000 --oltp-dist-type=uniform --rand-init=on --max-requests=0 --oltp-read-only=off --time=1800 --db-ps-mode=disable --oltp-skip-trx=on --mysql-ignore-errors=all {color:red}--threads=256{color} run

when i set --threads to less than 64, no errors reported. it seems like that when the concurrency is high, maxscale can't handle it.

below attached my maxscale.cnf, i don't know if any mistake in the config file.

[maxscale]
threads=auto
logdir=/tmp/
auth_connect_timeout=120
auth_read_timeout=120
auth_write_timeout=120
 
[server1]
type=server
address=10.60.230.112
port=3306
protocol=MySQLBackend
serv_weight=2
connection_timeout=86000
max_connections=1000
 
[server2]
type=server
address=10.60.40.254
port=3306
protocol=MySQLBackend
serv_weight=3
max_connections=1000
connection_timeout=86000
 
 
[MariaDB-Monitor]
type=monitor
module=mariadbmon
servers=server1,server2
user=monitor
passwd=monitor
monitor_interval=2000000
 
 
[Read-Write-Service]
type=service
router=readwritesplit
servers=server1,server2
user=proxytestuser
passwd=123456
max_slave_connections=100%
 
 
[MaxAdmin-Service]
type=service
router=cli
 
[Read-Write-Listener]
type=listener
service=Read-Write-Service
protocol=MySQLClient
port=4006
 
[MaxAdmin-Listener]
type=listener
service=MaxAdmin-Service
protocol=maxscaled
socket=default



 Comments   
Comment by markus makela [ 2018-04-16 ]

Does the MaxScale log contain any error messages?

Comment by Emma chan [ 2018-04-17 ]

no error in maxscale.log

Comment by Johan Wikman [ 2018-04-17 ]

emma How many cores do you have in your MaxScale machine?

Try changing threads=auto to e.g. threads=8.

Does it make any difference?

Comment by Emma chan [ 2018-04-18 ]

my MaxScale machine has 8 cores
I saw this in maxscale.log, I guess maxscale automatically config threads to 7
notice : MaxScale started with 7 worker threads, each with a stack size of 10485760 bytes.

Comment by Johan Wikman [ 2018-04-19 ]

Thanks emma, then there's nothing special about that. We'll have to investigate.

Comment by Timofey Turenko [ 2018-04-19 ]

I can't reproduce. Probably I use different HW and network.

Comment by Timofey Turenko [ 2018-05-29 ]

can't reproduce

Generated at Thu Feb 08 04:09:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.