# Issue with a single node in cluster seemingly doing all the bulk indexing!

**URL:** https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587
**Category:** Elasticsearch
**Created:** [September 18, 2015, 6:59pm UTC](https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587 "2015-09-18T18:59:45Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![asharif](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/asharif/32/8545_2.png) [@asharif](https://discuss.elastic.co/u/asharif)
#### Post date: [September 18, 2015, 6:59pm UTC](https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587/1 "2015-09-18T18:59:45Z")

</div>

So we have a 16 node cluster, indexes are spread across 16 shards. Up until last week it seemed to be correctly distributing across all the nodes/shards. The last couple days however it seems like a single node will take turns with most of the bulk indexing threads and the other nodes will have just a few.

running this:

curl -s "localhost:9200/\_cat/thread\_pool?v&h=host,bulk.max,bulk.size,bulk.active,bulk.queueSize,bulk.queue,bulk.rejected"

with a little bit of bash-fu yields:

host bulk.max bulk.size bulk.active bulk.queueSize bulk.queue bulk.rejected  
[es1-prod.aerserv.com](http://es1-prod.aerserv.com) 100 100 5 500 0 0  
[es2-prod.aerserv.com](http://es2-prod.aerserv.com) 100 100 7 500 0 0  
[es3-prod.aerserv.com](http://es3-prod.aerserv.com) 100 100 6 500 0 0  
[es4-prod.aerserv.com](http://es4-prod.aerserv.com) 100 100 18 500 0 0  
[es5-prod.aerserv.com](http://es5-prod.aerserv.com) 100 100 4 500 0 0  
[es6-prod.aerserv.com](http://es6-prod.aerserv.com) 100 100 100 500 43 0  
[es7-prod.aerserv.com](http://es7-prod.aerserv.com) 100 100 6 500 0 0  
[es8-prod.aerserv.com](http://es8-prod.aerserv.com) 100 100 7 500 0 0  
[es9-prod.aerserv.com](http://es9-prod.aerserv.com) 100 100 6 500 0 0  
[es10-prod.aerserv.com](http://es10-prod.aerserv.com) 100 100 5 500 0 0  
[es11-prod.aerserv.com](http://es11-prod.aerserv.com) 100 100 7 500 0 0  
[es12-prod.aerserv.com](http://es12-prod.aerserv.com) 100 100 6 500 0 0  
[es13-prod.aerserv.com](http://es13-prod.aerserv.com) 100 100 5 500 0 0  
[es14-prod.aerserv.com](http://es14-prod.aerserv.com) 100 100 6 500 0 0  
[es15-prod.aerserv.com](http://es15-prod.aerserv.com) 100 100 21 500 0 0  
[es16-prod.aerserv.com](http://es16-prod.aerserv.com) 100 100 7 500 0 0

see es6-prod as it's stuck at 100 bulk.active. all the other nodes are up and down but none get that high.

any ideas would be appriciated!

---

<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 19, 2015, 6:20am UTC](https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587/2 "2015-09-19T06:20:16Z")

</div>

How are you sending the bulks to the cluster?  
Are you sure the shards are balanced across your nodes?

---

<div class="post-metadata">

### Author: ![bcovi](https://avatars.discourse-cdn.com/v4/letter/b/8c91f0/32.png) [@bcovi](https://discuss.elastic.co/u/bcovi)
#### Post date: [September 21, 2015, 5:37pm UTC](https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587/3 "2015-09-21T17:37:53Z")

</div>

Hi, I'm working on the same cluster. It's well-behaved when conditions are nominal, but when the size of our main index approaches 3+ billion (daily indices, so toward the end of the day), things start to get out of balance. The bulk thread pool goes crazy on one node, and that node ends up at 99% cpu util and 45+ load. When the day "ticks over" and we start writing to a new, empty index, everything goes back to normal.

> How are you sending the bulks to the cluster?

Using the Bulk API via the Java TransportClient, in batches of 5000 events.

> Are you sure the shards are balanced across your nodes?

Yes. The cluster is 16 nodes in size, each index is split into 16 shards, and they're evenly distributed.

---

<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:49pm UTC](https://discuss.elastic.co/t/issue-with-a-single-node-in-cluster-seemingly-doing-all-the-bulk-indexing/29587/4 "2017-07-05T23:49:00Z")

</div>


