# Adding warm node to existing cluster, how to avoid existing indices to spread to these nodes

**URL:** <https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239>\
**Category:** Elasticsearch\
**Created:** [September 28, 2020, 5:04pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239 "2020-09-28T17:04:20Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Petr.Simik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/petr.simik/32/38082_2.png) [@Petr.Simik](https://discuss.elastic.co/u/Petr.Simik)\
**Post date:** [September 28, 2020, 5:04pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/1 "2020-09-28T17:04:20Z")

</div>

I plan to add 3 warm nodes into my cluster. (version 7.9 and 15 hot nodes)  
I modified elasticsearch.yml with these new lines:

> node.attr.data: hot # on existing nodes  
> node.attr.data: warm # on new nodes

when I start warm nodes, the cluster does not distinguish between warm/hot attr.data and indices are spread among all nodes.

How do I configure the cluster, that only ILM specific indices are copied to warm nodes. ?

it is not clear from [Implementing Hot-Warm-Cold in Elasticsearch with Index Lifecycle Management | Elastic Blog](https://www.elastic.co/blog/implementing-hot-warm-cold-in-elasticsearch-with-index-lifecycle-management)

based on

> **[Cluster-level shard allocation and routing settings | Elasticsearch Guide...](https://www.elastic.co/guide/en/elasticsearch/reference/7.9/modules-cluster.html#shard-allocation-awareness)**

should I configure on all nodes

> cluster.routing.allocation.awareness.attributes: data

it this correct approach?

---

<div class="post-metadata">

**Author:** ![Petr.Simik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/petr.simik/32/38082_2.png) [@Petr.Simik](https://discuss.elastic.co/u/Petr.Simik)\
**Post date:** [September 28, 2020, 6:30pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/2 "2020-09-28T18:30:22Z")

</div>

I found i some examples I could set in templates/indices

```auto
  "settings": {
    "index": {
      "routing.allocation.require.data": "hot"

```

is this an better approach than ?

> cluster.routing.allocation.awareness.attributes: data

Do I have to setup for all existing indices this settings?  
Can use cluster setup?

doing it template/index way it makes the management of hot/warm/cold quite complex.

I am looking for some simple how-to  
with example config setup.

It seems I have to create a template for \* all indices  
with setup of "index.routing.allocation.require.data": "hot"

or I have to modify default setting for indices if exists

for alle existsing cluster indices I have to configure this setting  
"index.routing.allocation.require.data": "hot"  
before I will add warm nodes

thank u

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [September 28, 2020, 10:51pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/3 "2020-09-28T22:51:45Z")

</div>

> [@Petr.Simik](#):
>
> is this an better approach than ?

That is the best approach.

> [@Petr.Simik](#):
>
> Do I have to setup for all existing indices this settings?

Yes you need to tag all nodes appropriately.

---

<div class="post-metadata">

**Author:** ![Petr.Simik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/petr.simik/32/38082_2.png) [@Petr.Simik](https://discuss.elastic.co/u/Petr.Simik)\
**Post date:** [September 29, 2020, 4:01am UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/4 "2020-09-29T04:01:30Z")

</div>

Thank you  
Is there a way I can configure cluster that all indices created will have "index.routing.allocation.require.data": "hot" without need of template.

so any index commands like this goes to hot nodes without need of template

> POST my-index/\_doc  
> {  
> "hello": "world"  
> }

This is my theoretical strategy to add warm nodes:

> 1. update all nodes elasticsearch.yml  
> node.attr.data: hot
> 
> 2. update all indices to have setting  
> { "settings": { "index.routing.allocation.require.data": "hot" }
> 
> 3. update all templates to have setting  
> { "settings": { "index.routing.allocation.require.data": "hot" }
> 
> 4. add warm nodes

```
(I am looking for default config, so all indices created will have this "index.routing.allocation.require.data": "hot" without need of template )

```

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [September 29, 2020, 4:09am UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/5 "2020-09-29T04:09:51Z")

</div>

The only other option is to do it manually.

---

<div class="post-metadata">

**Author:** ![Petr.Simik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/petr.simik/32/38082_2.png) [@Petr.Simik](https://discuss.elastic.co/u/Petr.Simik)\
**Post date:** [September 29, 2020, 4:05pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/6 "2020-09-29T16:05:16Z")

</div>

do I have to modify also system templates like "ilm-history"  
or I should keep this as is.

---

<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:** [October 27, 2020, 4:05pm UTC](https://discuss.elastic.co/t/adding-warm-node-to-existing-cluster-how-to-avoid-existing-indices-to-spread-to-these-nodes/250239/7 "2020-10-27T16:05:31Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
