# Logstash Performance Tuning

**URL:** https://discuss.elastic.co/t/logstash-performance-tuning/238088
**Category:** Logstash
**Created:** [June 22, 2020, 12:55pm UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088 "2020-06-22T12:55:32Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Jib\_Suwanachote](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jib_suwanachote/32/54682_2.png) [@Jib\_Suwanachote](https://discuss.elastic.co/u/Jib_Suwanachote)
#### Post date: [June 22, 2020, 12:55pm UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088/1 "2020-06-22T12:55:32Z")

</div>

Hi all

Currently our team use logstash run over container with K8S cluster for purpose consume data from KAFKA messaging and push data to Elasticsearch .As we're testing performance not good enough. we're setup only 3 pods of logstash and can consume only 100,000 msg/sec.But when we're try to add new pod after 3 pods performance not be better than that. so anyone can suggest about logstash tunning for high performance consume data from kafka.

# Existing logstash tuning parameter

Vcpu 4  
worker 16  
Batch size 3000  
Heap 4GB

---

<div class="post-metadata">

### Author: ![Rahul\_Kumar4](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rahul_kumar4/32/67369_2.png) [@Rahul\_Kumar4](https://discuss.elastic.co/u/Rahul_Kumar4)
#### Post date: [June 23, 2020, 1:45am UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088/2 "2020-06-23T01:45:14Z")

</div>

> [@Jib\_Suwanachote](#):
>
> But when we're try to add new pod after 3 pods performance not be better than that.

If the number of partitions of your Kafka topic is less than the number of Logstash consumers, you will always have idle Logstash pods and therefore not have any performance benefit of adding a new Logstash pod. Increase the number of partitions of your topic if your goal is to increase the indexing throughput.

---

<div class="post-metadata">

### Author: ![Jib\_Suwanachote](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jib_suwanachote/32/54682_2.png) [@Jib\_Suwanachote](https://discuss.elastic.co/u/Jib_Suwanachote)
#### Post date: [June 23, 2020, 10:55am UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088/3 "2020-06-23T10:55:01Z")

</div>

> [@Rahul\_Kumar4](#):
>
> If the number of partitions of your Kafka topic is less than the number of Logstash consumers, you will always have idle Logstash pods and therefore not have any performance benefit of adding a new Logstash pod. Increase the number of partitions of your topic if your goal is to increase the indexing throughput.

Thanks for your advice.we're using 3 nodes of kafka with 60 partitions/Topic Logstash consume is 3 Pods. Logstash pod isn't idle but we need consume perform speed up from logstash with low lag by consumer group.

---

<div class="post-metadata">

### Author: ![Rahul\_Kumar4](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rahul_kumar4/32/67369_2.png) [@Rahul\_Kumar4](https://discuss.elastic.co/u/Rahul_Kumar4)
#### Post date: [June 23, 2020, 3:48pm UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088/4 "2020-06-23T15:48:22Z")

</div>

There are some suggestions on tuning Logstash for scale - [https://www.elastic.co/guide/en/logstash/current/tuning-logstash.html](https://www.elastic.co/guide/en/logstash/current/tuning-logstash.html)

---

<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 21, 2020, 3:48pm UTC](https://discuss.elastic.co/t/logstash-performance-tuning/238088/5 "2020-07-21T15:48:32Z")

</div>

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