# Can I disable replicas in when index is getting data from logstash?

**URL:** https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647
**Category:** Elasticsearch
**Created:** [October 13, 2021, 4:01pm UTC](https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647 "2021-10-13T16:01:13Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![ElasticLiver](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elasticliver/32/64869_2.png) [@ElasticLiver](https://discuss.elastic.co/u/ElasticLiver)
#### Post date: [October 13, 2021, 4:01pm UTC](https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647/1 "2021-10-13T16:01:14Z")

</div>

Hi, I have a large quantity of data being indexed in elastic, is taking a long time to do it, so it is posible to disable replicas when data is being indexed to Elasticsearch? can this create any problem? it will speed up the indexing?

thanks!

```auto
PUT /twitter/_settings
{
    "index" : {
        "number_of_replicas" : 0
    }
}

```

---

<div class="post-metadata">

### Author: ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)
#### Post date: [October 13, 2021, 4:24pm UTC](https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647/2 "2021-10-13T16:24:44Z")

</div>

Assuming you have more than one data node in the cluster and a sufficient number of primary shards to spread the load it is likely to speed up indexing. This however comes at the cost of reduced resiliency and availability as data is not replicated.

---

<div class="post-metadata">

### Author: ![zx8086](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/zx8086/32/94917_2.png) [@zx8086](https://discuss.elastic.co/u/zx8086)
#### Post date: [October 13, 2021, 5:10pm UTC](https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647/3 "2021-10-13T17:10:15Z")

</div>

Where is the data coming from ? There are a few things you can do, by setting this in an index template for example or the configuration file of say a Beats shipper (Filebeat, Auditbeat, Metricbeat etc...)

I use zero replicas on my private setup... however the observability data from me is only for "in-the-moment" mostly, so I take the risk of data loss is something happens... but also it is a single node.

---

<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: [November 10, 2021, 5:11pm UTC](https://discuss.elastic.co/t/can-i-disable-replicas-in-when-index-is-getting-data-from-logstash/286647/4 "2021-11-10T17:11:11Z")

</div>

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