# Elasticseach out of memory issue

**URL:** <https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118>\
**Category:** Elasticsearch\
**Created:** [August 3, 2016, 2:44pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118 "2016-08-03T14:44:43Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![vikas\_J](https://avatars.discourse-cdn.com/v4/letter/v/7ba0ec/32.png) [@vikas\_J](https://discuss.elastic.co/u/vikas_J)\
**Post date:** [August 3, 2016, 2:44pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/1 "2016-08-03T14:44:43Z")

</div>

I have elasticsearch 2.3.4 version installed. However i find that it goes out of memory quite often. The ES\_HEAP\_SIZE is set to 1.5gb(which is 50% of available RAM). I found out that it could be because of the setting "indices.fielddata.cache.size" which is unlimited by default. I tried changing it by adding entry "indices.fielddata.cache.size: 30%" in elasticsearch.yml. But however elasticsearch doesnt recognize the property "indices.fielddata.cache.size". I dont understand the issue. According to elasticsearch documentation this key should be recognized by elasticsearch. Any inputs why this issue?

---

<div class="post-metadata">

**Author:** ![cbuescher](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cbuescher/32/60402_2.png) [@cbuescher](https://discuss.elastic.co/u/cbuescher)\
**Post date:** [August 3, 2016, 3:01pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/2 "2016-08-03T15:01:53Z")

</div>

What do you mean by

> [@vikas\_J](#):
>
> elasticsearch doesnt recognize the property "indices.fielddata.cache.size"

---

<div class="post-metadata">

**Author:** ![vikas\_J](https://avatars.discourse-cdn.com/v4/letter/v/7ba0ec/32.png) [@vikas\_J](https://discuss.elastic.co/u/vikas_J)\
**Post date:** [August 3, 2016, 3:25pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/3 "2016-08-03T15:25:41Z")

</div>

On adding indices.fielddata.cache.size: 30% in elasticsearch.yml, it throws parser exception like below:

`Aug 3 14:48:33 server-001 elasticsearch: Exception in thread "main" SettingsException[Failed to load settings from [elasticsearch.yml]]; nested: ParserException[while parsing a block mapping Aug 3 14:48:33 server-001 elasticsearch: in 'reader', line 50, column 1: Aug 3 14:48:33 server-001 elasticsearch: indices.fielddata.cache.size: 30% Aug 3 14:48:33 server-001 elasticsearch: ^ Aug 3 14:48:33 server-001 elasticsearch: expected <block end>, but found BlockMappingStart Aug 3 14:48:33 server-001 elasticsearch: in 'reader', line 55, column 2: Aug 3 14:48:33 server-001 elasticsearch: network.host: localhost Aug 3 14:48:33 server-001 elasticsearch: ^ Aug 3 14:48:33 server-001 elasticsearch:]; Aug 3 14:48:33 server-001 elasticsearch: Likely root cause: while parsing a block mapping Aug 3 14:48:33 server-001 elasticsearch: in 'reader', line 50, column 1: Aug 3 14:48:33 server-001 elasticsearch: indices.fielddata.cache.size: 30%`

---

<div class="post-metadata">

**Author:** ![cbuescher](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cbuescher/32/60402_2.png) [@cbuescher](https://discuss.elastic.co/u/cbuescher)\
**Post date:** [August 3, 2016, 3:38pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/4 "2016-08-03T15:38:46Z")

</div>

That looks like a broken config file, maybe some indentation issue? Hard to tell by just looking at the exception. I'd suggest you take a look at the config file around those lines that are showing up.

---

<div class="post-metadata">

**Author:** ![vikas\_J](https://avatars.discourse-cdn.com/v4/letter/v/7ba0ec/32.png) [@vikas\_J](https://discuss.elastic.co/u/vikas_J)\
**Post date:** [August 3, 2016, 3:42pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/5 "2016-08-03T15:42:35Z")

</div>

Oops...stupid me..I was missing a space . Thanks

---

<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:** [August 4, 2016, 6:33am UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/6 "2016-08-04T06:33:07Z")

</div>

WE don't usually recommend running ES with any decent amounts of data with less than 2GB of heap.

---

<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 5, 2017, 10:30pm UTC](https://discuss.elastic.co/t/elasticseach-out-of-memory-issue/57118/7 "2017-07-05T22:30:14Z")

</div>


