New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
connection_pool crash #1370
Comments
+-----------------------------------------------------+--------------------+ |
proxysql version 1.4.6 |
proxysql(_ZN15Query_Processor28query_parser_update_countersEP13MySQL_Session23MYSQL_COM_QUERY_commandP20__SQP_query_parser_ty+0x61)[0x496981] |
Hi. From the backtrace, the crash isn't related to connection pool but command counter. |
my OS is Linux 2.6.32-696.20.1.el6.x86_64 #1 SMP Fri Jan 26 17:51:45 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux |
We have a query of about 4000 per second,Load balancing by 3 proxysql. |
Thank you for the core dump. |
This happens for prepared statements, and mysql-query_digests=false
Fixed in 1.4.7 |
I will test this version after 2hours , thank you. |
hi @cggy2012 : any result? |
This happens for prepared statements, and mysql-query_digests=false
I'm sorry to reply to you so late , Because I can't test during the Spring Festival , Now one node is online , If there is no problem , I'll replace two other nodes tomorrow morning . by the way , I suggest setting mysql-client_found_rows default false. |
No problem, let me know when you have some result. |
OK , I will run 24 hours in production to test this version , Testing requires under high loads , And then I'll tell you the result . |
hello , So far , I haven't found any problems , I will continue to run in the production . There are two suggestions . first I have a error "MySQL_Session.cpp:2837:handler(): [WARNING] Error during query on (0,,3306): 1048, Column '' cannot be null" , I don't know which table or which sql have problem . second , I expect to have a function like general_log to find the cli_host of query . At last , If there is any problem I will be the first time to communicate with you . |
an other error "MySQL_Session.cpp:2837:handler(): [WARNING] Error during query on (1,,3306): 1290, The MySQL server is running with the --read-only option so it cannot execute this statement" , Occasionally, an update statement is sent to the wrong group . |
group 0 is read write , group 1 is read only . mysql> select * from runtime_mysql_query_rules \G |
the sql is UPDATE |
About the additional information in the error log, see #1060 (comment) . |
I use mysql group replication , 192.168.11.185 is primary node (read-write) , the other is slave node (read-only). proxySQL mysql_server proxySQL query_rules Run for a few hours , I get a error in proxysql.log "2018-02-23 16:38:02 MySQL_Session.cpp:2837:handler(): [WARNING] Error during query on (1,192.168.11.190,3306): 1290, The MySQL server is running with the --read-only option so it cannot execute this statement" normal , the update should sent to destination_hostgroup 0 , I used to have this problem , Especially in the morning rush hour . |
Are you using native support for Group Replication ? |
About the additional information in the error log, see #1060 (comment) . |
I think this problem is had to find out , because the error is very sample . |
search for the keyword “read-only” |
I use a script to detect the status of the mysql group replication and update mysql_server table . |
You should use native support for Group Replication, instead of this script.
Native group replication is faster. Can you also attach the output of |
thank you , I will make some adjustments . mysql> SELECT * FROM stats_mysql_connection_pool; |
It is not clear what is happening here. Neither it is clear if it is a problem with ProxySQL routing (probably not). |
There is no error in error log , I will use native support for Group Replication first , Then determine if there is still this problem . |
Yesterday there have been three read-only error . |
Is there a reason why |
I want to turn off some of the features I will not use . I will try to set mysql-query_digests=true . |
mysql> set mysql-query_digests = 'true'; mysql> LOAD MYSQL VARIABLES TO RUNTIME; mysql> SAVE MYSQL VARIABLES TO DISK; mysql> show variables like '%dig%'; mysql> select * from stats_mysql_query_digest; mysql> select * from stats_mysql_query_digest; When I set set mysql-query_digests = 'true' , It did not work .. |
also |
mysql> select * from stats_mysql_connection_pool;
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
| hostgroup | srv_host | srv_port | status | ConnUsed | ConnFree | ConnOK | ConnERR | Queries | Bytes_data_sent | Bytes_data_recv | Latency_us |
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
| 0 | 192.168.11.185 | 3306 | ONLINE | 1 | 18 | 19 | 0 | 11352 | 502377 | 29366200 | 0 |
| 1 | 192.168.11.185 | 3306 | OFFLINE_SOFT | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.186 | 3306 | ONLINE | 0 | 12 | 12 | 0 | 11322 | 2765800 | 5704774 | 0 |
| 1 | 192.168.11.187 | 3306 | ONLINE | 1 | 6 | 7 | 0 | 11321 | 2676833 | 6125501 | 0 |
| 1 | 192.168.11.188 | 3306 | ONLINE | 0 | 7 | 7 | 0 | 11553 | 2794793 | 5585408 | 0 |
| 1 | 192.168.11.189 | 3306 | ONLINE | 0 | 12 | 12 | 0 | 10401 | 2443517 | 6888625 | 0 |
| 2 | 192.168.11.190 | 3306 | ONLINE | 0 | 2 | 2 | 0 | 30 | 37086 | 885092 | 0 |
| 2 | 192.168.11.191 | 3306 | ONLINE | 0 | 2 | 2 | 0 | 33 | 41411 | 1515162 | 0 |
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
8 rows in set (0.00 sec)
mysql> select * from stats_mysql_connection_pool;
ERROR 2013 (HY000): Lost connection to MySQL server during query
mysql> select * from stats_mysql_connection_pool;
ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect...
Connection id: 1
Current database: *** NONE ***
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
| hostgroup | srv_host | srv_port | status | ConnUsed | ConnFree | ConnOK | ConnERR | Queries | Bytes_data_sent | Bytes_data_recv | Latency_us |
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
| 0 | 192.168.11.185 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.185 | 3306 | OFFLINE_SOFT | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.186 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.187 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.188 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 1 | 192.168.11.189 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 2 | 192.168.11.190 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| 2 | 192.168.11.191 | 3306 | ONLINE | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+-----------+----------------+----------+--------------+----------+----------+--------+---------+---------+-----------------+-----------------+------------+
The text was updated successfully, but these errors were encountered: