# Proxysql2 don't closes old clients coneections

**URL:** <https://forums.percona.com/t/proxysql2-dont-closes-old-clients-coneections/10957>\
**Category:** Percona XtraDB Cluster 5.x\
**Created:** [June 21, 2021, 9:36am UTC](https://forums.percona.com/t/proxysql2-dont-closes-old-clients-coneections/10957 "2021-06-21T09:36:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mikhail\_Ermolaev](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/mikhail_ermolaev/32/2953_2.png) [@Mikhail\_Ermolaev](https://forums.percona.com/u/Mikhail_Ermolaev)\
**Post date:** [June 21, 2021, 9:36am UTC](https://forums.percona.com/t/proxysql2-dont-closes-old-clients-coneections/10957/1 "2021-06-21T09:36:17Z")

</div>

Ubuntu 20.04, proxySQL 2.0.18-percona-1.1, XtraDB 5.7.33-36-57 - Percona XtraDB Cluster (GPL).  
A pool of connections via python is used.  
Now unused connections are live up to mysql-wait\_timeout = 28800000. On proxySQL 1.4 connections were died when the time was coming time wait\_timeout=500 (interactive\_timeout=500) (variation and global ariation) on the backend for the same backend.

Proxysql processlist:  
mysql\> select \* from stats.stats\_mysql\_processlist where user=‘user’ order by time\_ms desc;  
±---------±----------±-------------------±--------±----------±---------±----------±-----------±-----------±---------±---------±--------±--------±-----±-------------±--------------+  
| ThreadID | SessionID | user | db | cli\_host | cli\_port | hostgroup | l\_srv\_host | l\_srv\_port | srv\_host | srv\_port | command | time\_ms | info | status\_flags | extended\_info |  
±---------±----------±-------------------±--------±----------±---------±----------±-----------±-----------±---------±---------±--------±--------±-----±-------------±--------------+  
| 1 | 811 | user | db\_main | 10.0.3.52 | 42674 | 0 | NULL | NULL | NULL | NULL | Sleep | 6395795 | NULL | NULL | NULL |  
| 0 | 812 | user | db\_main | 10.0.3.52 | 42676 | 0 | NULL | NULL | NULL | NULL | Sleep | 6395792 | NULL | NULL | NULL

Proxysql runtime variables:  
mysql\> select \* from runtime\_global\_variables where variable\_name like ‘%mysql-wait\_timeout%’;  
±-------------------±---------------+  
| variable\_name | variable\_value |  
±-------------------±---------------+  
| mysql-wait\_timeout | 28800000 |  
±-------------------±---------------+

XtraDB variables:  
mysql\> show variables like ‘wait\_timeout%’;  
±--------------±------+  
| Variable\_name | Value |  
±--------------±------+  
| wait\_timeout | 500 |  
±--------------±------+

mysql\> show variables like ‘interactive\_timeout%’;  
±--------------------±------+  
| Variable\_name | Value |  
±--------------------±------+  
| interactive\_timeout | 500 |  
±--------------------±------+

How to return proxySQL2 the same behavior of proxySQL1 that took into account the wait\_timeout parameter on the backend?

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [July 6, 2021, 5:22pm UTC](https://forums.percona.com/t/proxysql2-dont-closes-old-clients-coneections/10957/2 "2021-07-06T17:22:10Z")

</div>

In ProxySQL, change `mysql-wait_timeout` to match that of `wait_timout`.
