# Is bulk index sending to data nodes better or non-data nodes?

**URL:** <https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690>\
**Category:** Elasticsearch\
**Created:** [March 16, 2015, 3:40pm UTC](https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690 "2015-03-16T15:40:53Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![chenryn](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/chenryn/32/44917_2.png) [@chenryn](https://discuss.elastic.co/u/chenryn)\
**Post date:** [March 16, 2015, 3:40pm UTC](https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690/1 "2015-03-16T15:40:53Z")

</div>

Hello, anyone.  
I used to setup some non-data nodes to accept bulk indexing from my  
logstash/outputs/elasticsearch(http protocol). But some day I found one  
article suggested use client node for searching but data node for bulk  
indexing.

```
So, what's the best practical? Which node should we send bulk to,

```

master, data, client?

```
thanks~

```

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)\
**Post date:** [March 16, 2015, 4:07pm UTC](https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690/2 "2015-03-16T16:07:58Z")

</div>

Which article is that?

It does not matter, you can send search and bulk requests to all nodes. ES  
will do the routing and automatically forward the requests to the nodes  
where they can be executed.

Jörg

On Mon, Mar 16, 2015 at 4:40 PM, chenlin rao [rao.chenlin@gmail.com](mailto:rao.chenlin@gmail.com) wrote:

> Hello, anyone.  
> I used to setup some non-data nodes to accept bulk indexing from my  
> logstash/outputs/elasticsearch(http protocol). But some day I found one  
> article suggested use client node for searching but data node for bulk  
> indexing.
> 
> ```
> So, what's the best practical? Which node should we send bulk to,
> 
> ```
> 
> master, data, client?
> 
> ```
> thanks~
> 
> ```
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com)  
> [https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![andrew](https://avatars.discourse-cdn.com/v4/letter/a/f19dbf/32.png) [@andrew](https://discuss.elastic.co/u/andrew)\
**Post date:** [March 16, 2015, 4:27pm UTC](https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690/3 "2015-03-16T16:27:03Z")

</div>

It’s completely true that you can send requests to any node, however in practice one does not typically send requests directly to master nodes. It’s best to leave the master nodes alone so they can focus on maintaining global cluster state.

You can safely send bulk requests to either client or data nodes. The only difference is that the node that receives the request will sub-divide the bulk requests into per-node sub-bulk-requests and forward them on, then receive the results before sending back to the caller. In practice many people prefer to create a pool of client nodes and round-robin requests amongst them, never directly talking to the data nodes. Your mileage may vary, but this is a good rule of thumb and I would recommend following that general practice.

- Andrew

> On Mar 16, 2015, at 9:07 AM, [joergprante@gmail.com](mailto:joergprante@gmail.com) wrote:
> 
> Which article is that?
> 
> It does not matter, you can send search and bulk requests to all nodes. ES will do the routing and automatically forward the requests to the nodes where they can be executed.
> 
> Jörg
> 
> On Mon, Mar 16, 2015 at 4:40 PM, chenlin rao \<[rao.chenlin@gmail.com](mailto:rao.chenlin@gmail.com) [mailto:rao.chenlin@gmail.com](mailto:rao.chenlin@gmail.com)\> wrote:  
> Hello, anyone.  
> I used to setup some non-data nodes to accept bulk indexing from my logstash/outputs/elasticsearch(http protocol). But some day I found one article suggested use client node for searching but data node for bulk indexing.
> 
> ```
> So, what's the best practical? Which node should we send bulk to, master, data, client?
> 
> thanks~
> 
> ```
> 
> --  
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com) [mailto:elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com) [https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CABwsoohg%3Dh0WoC7p%3Do11whbEsBxjpiSXu%2BMVqnKKJYSrq7%3Dscw%40mail.gmail.com?utm_medium=email&utm_source=footer).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout) [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com) [mailto:elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com) [https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CAKdsXoHMrNLSy8qUtNLrd0xNVyNdqThho4ySPVezxBNN%2BSpKjw%40mail.gmail.com?utm_medium=email&utm_source=footer).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout) [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/A0F337FC-9993-47EC-AC29-5E287BE9332B%40elastic.co](https://groups.google.com/d/msgid/elasticsearch/A0F337FC-9993-47EC-AC29-5E287BE9332B%40elastic.co).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 12:26am UTC](https://discuss.elastic.co/t/is-bulk-index-sending-to-data-nodes-better-or-non-data-nodes/22690/4 "2017-07-06T00:26:30Z")

</div>


