# X-pack ML job gives the following

**URL:** https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027
**Category:** Elasticsearch
**Tags:** elastic-stack-machine-learning
**Created:** [November 16, 2017, 9:38pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027 "2017-11-16T21:38:57Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![mathurin68](https://avatars.discourse-cdn.com/v4/letter/m/6bbea6/32.png) [@mathurin68](https://discuss.elastic.co/u/mathurin68)
#### Post date: [November 16, 2017, 9:38pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027/1 "2017-11-16T21:38:57Z")

</div>

2 weeks and probably about 15,000,000 records in a ML Job giving me the following error-

[2017-03-24T11:38:07,458][WARN][o.e.m.j.JvmGcMonitorService] [es154.162.client2] [gc][816] overhead, spent [925ms] collecting in the last [1s]  
[2017-03-24T11:38:12,327][WARN][o.e.m.j.JvmGcMonitorService] [es154.162.client2] [gc][820] overhead, spent [956ms] collecting in the last [1.8s]  
[2017-03-24T11:38:14,482][WARN][o.e.m.j.JvmGcMonitorService] [es154.162.client2] [gc][822] overhead, spent [948ms] collecting in the last [1.1s]  
[2017-03-24T11:38:16,924][WARN][o.e.m.j.JvmGcMonitorService] [es154.162.client2] [gc][823] overhead, spent [1.6s] collecting in the last [2.4s]

shutsdown elasticsearch etc. I'm still figuring out x-pack etc so there's probably something I'm doing. It's a really beefy server.

There's a couple other questions like this but no answers.

---

<div class="post-metadata">

### Author: ![mathurin68](https://avatars.discourse-cdn.com/v4/letter/m/6bbea6/32.png) [@mathurin68](https://discuss.elastic.co/u/mathurin68)
#### Post date: [November 17, 2017, 2:22pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027/2 "2017-11-17T14:22:14Z")

</div>

Everything I'm reading says this is a memory error but it looks ok..  
root@elkstack:/var/log/elasticsearch# free -mh  
total used free shared buff/cache available  
Mem: 251G 4.8G 133G 2.6G 113G 242G  
Swap: 5.3G 0B 5.3G

---

<div class="post-metadata">

### Author: ![dkyle](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dkyle/32/59114_2.png) [@dkyle](https://discuss.elastic.co/u/dkyle)
#### Post date: [November 17, 2017, 3:00pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027/3 "2017-11-17T15:00:04Z")

</div>

Hi,

You can configure the amount of memory the JVM uses by editing the jvm.options file in the Elasticsearch config directory. Take a look at the [documentation](https://www.elastic.co/guide/en/elasticsearch/reference/current/heap-size.html) for more details.

The default out of the box setting it 1G, you have a big machine so a much larger value is fine but don't give the JVM more than 26Gb of memory as it can no longer use compressed oops. `-Xms26g` and `-Xmx26g` are the max values you should use.

---

<div class="post-metadata">

### Author: ![mathurin68](https://avatars.discourse-cdn.com/v4/letter/m/6bbea6/32.png) [@mathurin68](https://discuss.elastic.co/u/mathurin68)
#### Post date: [November 17, 2017, 9:26pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027/4 "2017-11-17T21:26:01Z")

</div>

Solved, thanks David!!!

---

<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: [December 15, 2017, 9:26pm UTC](https://discuss.elastic.co/t/x-pack-ml-job-gives-the-following/108027/5 "2017-12-15T21:26:48Z")

</div>

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