# Elasticsearch Default Replica Value

**URL:** <https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593>\
**Category:** Elasticsearch\
**Created:** [March 19, 2018, 3:20pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593 "2018-03-19T15:20:15Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Tony\_Chirillo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tony_chirillo/32/22647_2.png) [@Tony\_Chirillo](https://discuss.elastic.co/u/Tony_Chirillo)\
**Post date:** [March 19, 2018, 3:20pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/1 "2018-03-19T15:20:15Z")

</div>

In Elasticsearch 6.2 is there a setting somewhere that assigns a default replica value of "1" somewhere?

Our index templates do not assign a replica value, but our indexes are indeed replicated. We would like to know where the replica config ordinates from.

-Tony

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 19, 2018, 3:37pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/2 "2018-03-19T15:37:26Z")

</div>

It's a builtin default value. You can overwrite this by setting your own index template: [https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-templates.html)

```auto
PUT _template/replicas_0
{
  "index_patterns": ["*"],
  "settings": {
    "number_of_replicas": 0
  }
}

```

---

<div class="post-metadata">

**Author:** ![Tony\_Chirillo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tony_chirillo/32/22647_2.png) [@Tony\_Chirillo](https://discuss.elastic.co/u/Tony_Chirillo)\
**Post date:** [March 19, 2018, 3:49pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/3 "2018-03-19T15:49:31Z")

</div>

Are you saying the "builtin default value" is not changeable itself? I knew the value could be overwritten with the the use of the index templates.

Thanks for the response!

-Tony

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [March 19, 2018, 4:20pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/4 "2018-03-19T16:20:20Z")

</div>

> Are you saying the "builtin default value" is not changeable itself?

It is. But with an index template. The built-in default value is basically like an index template with the lowest priority.

Otherwise, if you really want to overwrite the default value, then you need to change the source code and recompile with your default value. I'm pretty sure you will prefer an index template 😛

---

<div class="post-metadata">

**Author:** ![Tony\_Chirillo](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tony_chirillo/32/22647_2.png) [@Tony\_Chirillo](https://discuss.elastic.co/u/Tony_Chirillo)\
**Post date:** [March 19, 2018, 5:09pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/5 "2018-03-19T17:09:36Z")

</div>

Ok. Makes sense! Thanks.

-Tony

---

<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:** [April 16, 2018, 5:09pm UTC](https://discuss.elastic.co/t/elasticsearch-default-replica-value/124593/6 "2018-04-16T17:09:56Z")

</div>

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