# Garbage collection runs

**URL:** <https://community.graylog.org/t/garbage-collection-runs/22868>\
**Category:** Graylog Central (peer support)\
**Created:** [March 4, 2022, 2:17pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868 "2022-03-04T14:17:11Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sharzad](https://avatars.discourse-cdn.com/v4/letter/s/35a633/32.png) [@Sharzad](https://community.graylog.org/u/Sharzad)\
**Post date:** [March 4, 2022, 2:17pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868/1 "2022-03-04T14:17:11Z")

</div>

I have following error on graylog4 on ubuntu 20:  
There are Graylog nodes on which the garbage collector runs too long. Garbage collection runs should be as short as possible. Please check whether those nodes are healthy. (Node: _7809e611-f490-4f51-b594-3381b3928d59_ , GC duration: _1233 ms_ , GC threshold: _1000 ms_ )  
What should i do? what does it mean?

---

<div class="post-metadata">

**Author:** ![gsmith](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gsmith/32/1222_2.png) [@gsmith](https://community.graylog.org/u/gsmith)\
**Post date:** [March 4, 2022, 11:58pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868/2 "2022-03-04T23:58:16Z")

</div>

Hello,

> [@Sharzad](#):
>
> garbage collector runs too long

check on memory usage by ES, in my case the ES\_HEAP\_SIZE needed some manual  
fiddling.

`output_batch_size = 25 this can be something like 500`

check on max\_file\_descriptors from your os. don’t know for ubuntu 20

EDIT: Perhaps set the refresh interval to 30

 ![image](https://us1.discourse-cdn.com/flex016/uploads/graylog/original/2X/f/fee068dd23df691531bb2d8497fe9d275aa85e28.png)

> [@Sharzad](#):
>
> what does it mean?

If the heap memory is full and if the garbage collector is unable to free more memory, the application will crash with an out of memory error the next time it tries to allocate memory.

---

<div class="post-metadata">

**Author:** ![Sharzad](https://avatars.discourse-cdn.com/v4/letter/s/35a633/32.png) [@Sharzad](https://community.graylog.org/u/Sharzad)\
**Post date:** [March 5, 2022, 8:59pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868/3 "2022-03-05T20:59:40Z")

</div>

i can’t find  
output\_batch\_size = 25 in my elasticksearch.yml or java.option

---

<div class="post-metadata">

**Author:** ![gsmith](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gsmith/32/1222_2.png) [@gsmith](https://community.graylog.org/u/gsmith)\
**Post date:** [March 8, 2022, 10:31pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868/4 "2022-03-08T22:31:27Z")

</div>

Hello,

> [@Sharzad](#):
>
> output\_batch\_size = 25 in my elasticksearch.yml or java.option

Its not in those files, need to look in Graylog configuration file.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/graylog/original/3X/c/7/c7c09c6b5099570133d6502b83f50ba4430de5b6.png) [@system](https://community.graylog.org/u/system)\
**Post date:** [March 22, 2022, 10:32pm UTC](https://community.graylog.org/t/garbage-collection-runs/22868/5 "2022-03-22T22:32:12Z")

</div>

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