# Threadpool cluster persistent settings 1.7.3

**URL:** <https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496>\
**Category:** Elasticsearch\
**Created:** [December 7, 2015, 7:30am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496 "2015-12-07T07:30:01Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![anishek](https://avatars.discourse-cdn.com/v4/letter/a/b77776/32.png) [@anishek](https://discuss.elastic.co/u/anishek)\
**Post date:** [December 7, 2015, 7:30am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/1 "2015-12-07T07:30:01Z")

</div>

Hello,

We are using ES 1.7.3 - primarily as an execution engine using percolation. Rules we have uses significant CPU resources and hence we have powerful 40 core machines. Looking at the default threadpool settings using

```
curl 'localhost:9200/_cat/thread_pool?v&h=percolate.size,percolate.max,percolate.type,percolate.min,percolate.max,h'

```

i get 32 as the value. I am trying to update it to 40 using

```
curl -XPUT localhost:9200/_cluster/settings -d '
{
  "persistent" : {
	"threadpool.percolate.type" : "fixed",
	"threadpool.percolate.max" : 40
   }
}'

```

on

```
curl -XGET localhost:9200/_cluster/settings?pretty
{
  "persistent": {
    "threadpool": {
      "percolate": {
          "type": "fixed",
         "max": "40"
         }
     }
  },
  "transient": {}
}

```

but when i look at

```
curl 'localhost:9200/_cat/thread_pool?v&h=percolate.size,percolate.max,percolate.type,percolate.min,percolate.max,h'

```

it still shows it at 32. I have tried a restart but still same problem. Why is the value not reflected in the thread\_pool cat query ? Any help would be greatly appreciated. Thanks in advance !!

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [December 7, 2015, 8:13am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/2 "2015-12-07T08:13:34Z")

</div>

I think you need to use `size` and not `max`. `max` is for non fixed thread pools IIRC.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [December 7, 2015, 8:15am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/4 "2015-12-07T08:15:09Z")

</div>

Yes. This is what I meant. Read this: [https://www.elastic.co/guide/en/elasticsearch/reference/1.7/modules-threadpool.html#\_literal\_fixed\_literal](https://www.elastic.co/guide/en/elasticsearch/reference/1.7/modules-threadpool.html#_literal_fixed_literal)

---

<div class="post-metadata">

**Author:** ![anishek](https://avatars.discourse-cdn.com/v4/letter/a/b77776/32.png) [@anishek](https://discuss.elastic.co/u/anishek)\
**Post date:** [December 7, 2015, 8:17am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/5 "2015-12-07T08:17:02Z")

</div>

Thanks that worked.

Another question the link says its number of cores times 5 but that would be 40 \* 5 = 200. Should i set such a high number ? or limit it to 1 per core.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [December 7, 2015, 8:25am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/6 "2015-12-07T08:25:47Z")

</div>

I suspect that you have troubles as you want to change default values.  
If so, you can imagine dedicating some nodes for percolation only.

Basically, use this: [https://www.elastic.co/guide/en/elasticsearch/reference/current/shard-allocation-filtering.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/shard-allocation-filtering.html)  
Send your "percolator" indices to those nodes.

Then test again with the default configuration. And monitor the CPU usage to see if you are reaching the limit.  
If not, you can increase the thread pool size or add more nodes to spread the load on more nodes.

But I'm speaking here without any knowledge about issues you may have today. Feel free to add more details about your setup and what you are doing.

---

<div class="post-metadata">

**Author:** ![anishek](https://avatars.discourse-cdn.com/v4/letter/a/b77776/32.png) [@anishek](https://discuss.elastic.co/u/anishek)\
**Post date:** [December 7, 2015, 8:30am UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/7 "2015-12-07T08:30:05Z")

</div>

Thanks a lot @dadoonet , we are using es only as rule engine no data just percolation queries and matching them against docs we throw at them. The most cpu intensive aspect i think is the geo filter we are using, typical queries have about 2000-3000 such filters but really large ones go upto 40000 such filters in percolation queries. Our target was given to be 1500 points matching but now business is saying they want about 40k-50k per query and hence we are trying to scale cluster horizontally, we have powerful machines now but threads was seeming a bit wierd.

Ty for the help, looks like more changes and monitoring for now.

---

<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 5, 2017, 11:33pm UTC](https://discuss.elastic.co/t/threadpool-cluster-persistent-settings-1-7-3/36496/8 "2017-07-05T23:33:07Z")

</div>


