# How can I temporary disable filebeat in a Kafka downtime?

**URL:** <https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [February 6, 2017, 6:10am UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011 "2017-02-06T06:10:45Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [February 6, 2017, 6:10am UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011/1 "2017-02-06T06:10:45Z")

</div>

Hi,

I have a number of filebeats, sending data to Kafka, with number worker set to 2. I have Kafka downtimes, and when it becomes available, Filebeats sends a huge data as a bulk. Refer the below trace;

```
[2017-02-03 09:13:54,813] WARN Unexpected error from /192.168.0.1; closing connection (org.apache.kafka.common.network.Selector)
org.apache.kafka.common.network.InvalidReceiveException: Invalid receive (size = 842019127 larger than 104857600)
        at org.apache.kafka.common.network.NetworkReceive.readFromReadableChannel(NetworkReceive.java:91)
        at org.apache.kafka.common.network.NetworkReceive.readFrom(NetworkReceive.java:71)
        at org.apache.kafka.common.network.KafkaChannel.receive(KafkaChannel.java:154)
        at org.apache.kafka.common.network.KafkaChannel.read(KafkaChannel.java:135)
        at org.apache.kafka.common.network.Selector.pollSelectionKeys(Selector.java:323)
        at org.apache.kafka.common.network.Selector.poll(Selector.java:283)
        at kafka.network.Processor.poll(SocketServer.scala:472)
        at kafka.network.Processor.run(SocketServer.scala:412)
        at java.lang.Thread.run(Thread.java:745)

```

I would like to temporarily disable Filebeats / discard the filebeat outputs in a Kafka downtime. How can I do that?

Thank you.

---

<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:** [February 6, 2017, 7:44am UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011/2 "2017-02-06T07:44:51Z")

</div>

You cannot, it should realise kafka is unavailable and stop processing though.

---

<div class="post-metadata">

**Author:** ![elasticheart](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticheart/32/65189_2.png) [@elasticheart](https://discuss.elastic.co/u/elasticheart)\
**Post date:** [February 6, 2017, 7:47am UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011/3 "2017-02-06T07:47:34Z")

</div>

Ok.. so will `reachable_only: true` solve my problem?

---

<div class="post-metadata">

**Author:** ![steffens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steffens/32/79630_2.png) [@steffens](https://discuss.elastic.co/u/steffens)\
**Post date:** [February 6, 2017, 3:35pm UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011/4 "2017-02-06T15:35:40Z")

</div>

when using `reachable_only: true`, please also take potential resource usage into account. See [note](https://www.elastic.co/guide/en/beats/filebeat/current/kafka-output.html#_partition).

Also consider enabling quotas in kafka: [http://kafka.apache.org/documentation/#design\_quotas](http://kafka.apache.org/documentation/#design_quotas)

---

<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:** [March 6, 2017, 3:35pm UTC](https://discuss.elastic.co/t/how-can-i-temporary-disable-filebeat-in-a-kafka-downtime/74011/5 "2017-03-06T15:35:51Z")

</div>

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