Maxscale - after update Prepared_stmt_count is getting very high
Hi,
After we upgraded our Maxscale instance from 6.3 to 23.08 we had issues because the max_prepared_stmt_count limit was reached. And we started to receive "Can't create more than max_prepared_stmt_count statements (current value: 16382)" errors.
The Com_stmt_close counter was going up very slow, but could not hold up.
A friend of mine has seen this behaviour with ProxySQL too; the cause here was that multiplexed connections do not close the connection after an prepared statement (insert in this case).
I downgraded the instance to 6.3 and it works again without problems (max_prepared_stmt_count is stable at 80)
I already checked changelogs for changes, but could not find any.
This is my config:
# Globals [maxscale] threads=auto log_debug=1 # Admin is enabled but behind nginx proxy, so thats why only http admin_secure_gui = false [db1] type=server address=172.31.32.21 port=3306 protocol=MySQLBackend [db2] type=server address=172.31.32.22 port=3306 protocol=MySQLBackend [db3] type=server address=172.31.32.23 port=3306 protocol=MySQLBackend [Galera-Monitor] type=monitor module=galeramon servers=db1,db2,db3 user=maxscale password=xxxxxxx monitor_interval=1000 # Galera router service [Galera-Service] type=service router=readwritesplit servers=db1,db2,db3 user=maxscale password=xxxxxxx enable_root_user=1 max_connections=1800 connection_timeout=60 # Galera cluster listener [Galera-Listener] type=listener service=Galera-Service protocol=MariaDBClient port=3306 address=0.0.0.0
Answer Answered by Markus Mäkelä in this comment.
I'm fairly certain that it's a bug in MaxScale 23.08 (MXS-4969).