# Unable to activate keep\_alive

**URL:** <https://discuss.elastic.co/t/unable-to-activate-keep-alive/8228>\
**Category:** Elasticsearch\
**Created:** [June 26, 2012, 12:31pm UTC](https://discuss.elastic.co/t/unable-to-activate-keep-alive/8228 "2012-06-26T12:31:35Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Benoit](https://avatars.discourse-cdn.com/v4/letter/b/5daacb/32.png) [@Benoit](https://discuss.elastic.co/u/Benoit)\
**Post date:** [June 26, 2012, 12:31pm UTC](https://discuss.elastic.co/t/unable-to-activate-keep-alive/8228/1 "2012-06-26T12:31:35Z")

</div>

Hello,

I've added

```
network.tcp.keep_alive: true 

```

to elasticsearch.yml to activate keep alive.

After resart, nothing change :

```
$ curl -I http://localhost:9200
HTTP/1.1 200 OK
Content-Type: text/plain; charset=UTF-8
Content-Length: 0

```

Any idea ? How to check if an option from elasticsearch.yml is took into  
account ?

Thanks, regards.

Benoît

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [June 26, 2012, 2:23pm UTC](https://discuss.elastic.co/t/unable-to-activate-keep-alive/8228/2 "2012-06-26T14:23:30Z")

</div>

This control the TCP level socket keep alive setting, not HTTP. In terms of  
HTTP, elasticsearch supports keep alive setting, and won't close the socket  
if using HTTP 1.1 (and no CLOSE in the header), or when using HTTP 1.0 with  
keep alive header (according to the spec).

On Tue, Jun 26, 2012 at 2:31 PM, Benoît [benoit.intrw@gmail.com](mailto:benoit.intrw@gmail.com) wrote:

> Hello,
> 
> I've added
> 
> ```
> network.tcp.keep_alive: true
> 
> ```
> 
> to elasticsearch.yml to activate keep alive.
> 
> After resart, nothing change :
> 
> ```
> $ curl -I http://localhost:9200
> HTTP/1.1 200 OK
> Content-Type: text/plain; charset=UTF-8
> Content-Length: 0
> 
> ```
> 
> Any idea ? How to check if an option from elasticsearch.yml is took into  
> account ?
> 
> Thanks, regards.
> 
> Benoît

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 3:22am UTC](https://discuss.elastic.co/t/unable-to-activate-keep-alive/8228/3 "2017-07-06T03:22:27Z")

</div>


