# Persistent connections (1.4)

**URL:** <https://discourse.haproxy.org/t/persistent-connections-1-4/549>\
**Category:** Help!\
**Created:** [August 8, 2016, 6:51pm UTC](https://discourse.haproxy.org/t/persistent-connections-1-4/549 "2016-08-08T18:51:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pablo](https://sea2.discourse-cdn.com/flex016/user_avatar/discourse.haproxy.org/pablo/32/107_2.png) [@pablo](https://discourse.haproxy.org/u/pablo)\
**Post date:** [August 8, 2016, 6:51pm UTC](https://discourse.haproxy.org/t/persistent-connections-1-4/549/1 "2016-08-08T18:51:15Z")

</div>

Howdy folks!

I’m new with HAProxy and using HAProxy mostly for TCP connection (non-HTTP). The main use is as a proxy in the middle between our application and our backend services.

One of the issues I’m trying to find how to fix is to prevent HAProxy in opening a new connection each time it talks to a backend server. As mentioned in the subject, the version I’m running is 1.4 (1.4.24) which _might_ be a bit old :).

Is there a way to make HAProxy have some type of connection pooling? The closest I can describe is mcrouter where it opens connections to the memcache hosts and keeps the connections open all the time so it avoids all the TCP hand-shake all the time.

fwiw I already tried the tcpka options but that only sets the TCP flag (confirmed by ss -e) but HAProxy is still closing and opening new connections.

Thanks!

---

<div class="post-metadata">

**Author:** ![lukastribus](https://avatars.discourse-cdn.com/v4/letter/l/7ea924/32.png) [@lukastribus](https://discourse.haproxy.org/u/lukastribus)\
**Post date:** [August 9, 2016, 9:00am UTC](https://discourse.haproxy.org/t/persistent-connections-1-4/549/2 "2016-08-09T09:00:28Z")

</div>

You have to upgrade to haproxy 1.6 and use the [http-reuse](http://cbonte.github.io/haproxy-dconv/1.6/configuration.html#4.2-http-reuse) feature.

1.5 supports keep-alive mode, but only for one specific sessions.

1.4 only supports http-tunneling (switching to TCP mode after the first HTTP transaction).
