# How can I generate a full Elasticsearch configuration?

**URL:** <https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012>\
**Category:** Elasticsearch\
**Created:** [October 11, 2018, 8:40am UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012 "2018-10-11T08:40:53Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![JohnBlack](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/johnblack/32/46447_2.png) [@JohnBlack](https://discuss.elastic.co/u/JohnBlack)\
**Post date:** [October 11, 2018, 8:40am UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012/1 "2018-10-11T08:40:53Z")

</div>

I have only basic settings in the `elasticsearch.yml` file. I configured the rest of the elasticsearch settings using the `REST API`. I wonder whether it is possible to generate a full configuration containing the settings set in the file `elasticsearch.yml`, `REST API` etc.?

---

<div class="post-metadata">

**Author:** ![dakrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dakrone/32/23351_2.png) [@dakrone](https://discuss.elastic.co/u/dakrone)\
**Post date:** [October 11, 2018, 10:25am UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012/2 "2018-10-11T10:25:14Z")

</div>

Hi John,

There isn't a way to generate an `elasticsearch.yml` with all these settings, but you can retrieve every setting that ES supports with:

```auto
GET /_cluster/settings?include_defaults=true

```

Which will return all the settings and their default values from the REST API

---

<div class="post-metadata">

**Author:** ![JohnBlack](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/johnblack/32/46447_2.png) [@JohnBlack](https://discuss.elastic.co/u/JohnBlack)\
**Post date:** [October 11, 2018, 12:57pm UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012/3 "2018-10-11T12:57:40Z")

</div>

Hi Lee,

Thank you for your answer. It seems to be working properly but why there are no such fields for instance like `number_of_replicas` or `max_thread_count`?

---

<div class="post-metadata">

**Author:** ![dakrone](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dakrone/32/23351_2.png) [@dakrone](https://discuss.elastic.co/u/dakrone)\
**Post date:** [October 14, 2018, 2:54am UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012/4 "2018-10-14T02:54:25Z")

</div>

> [@JohnBlack](#):
>
> It seems to be working properly but why there are no such fields for instance like `number_of_replicas` or `max_thread_count` ?

Some of these settings are a little special, but I agree that they should be included in the output, if you are not seeing them can you open an issue at [Issues · elastic/elasticsearch · GitHub](https://github.com/elastic/elasticsearch/issues) so they can be added?

---

<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 11, 2018, 2:54am UTC](https://discuss.elastic.co/t/how-can-i-generate-a-full-elasticsearch-configuration/152012/5 "2018-11-11T02:54:25Z")

</div>

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