# Troubleshooting Memory Leak from OneAgent installed on the server

**URL:** <https://community.dynatrace.com/t/troubleshooting-memory-leak-from-oneagent-installed-on-the-server/38917>\
**Category:** Open Q&A\
**Tags:** memory-dump, oneagent, processes\
**Created:** [March 21, 2023, 4:18am UTC](https://community.dynatrace.com/t/troubleshooting-memory-leak-from-oneagent-installed-on-the-server/38917 "2023-03-21T04:18:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ardhi](https://avatars.discourse-cdn.com/v4/letter/a/e99b99/32.png) [@Ardhi](https://community.dynatrace.com/u/Ardhi)\
**Post date:** [March 21, 2023, 4:18am UTC](https://community.dynatrace.com/t/troubleshooting-memory-leak-from-oneagent-installed-on-the-server/38917/1 "2023-03-21T04:18:34Z")

</div>

Hi,

We’re currently troubleshooting memory leak (gradually increased over days) everytime OneAgent is installed in our Java server.

We have narrowed down the issue by updating to the latest OneAgent version, downloading support archive dump files, disabling full stack monitoring, deep monitoring, checking for bugs in certain Java version, NMT output from when the problem occurs, and came into conclusion that the leak occuring in the native memory.

Then we were using&nbsp;oneagentdumpproc command to dump the native process however still couldn’t find the issue.

Developer suggested to&nbsp;disable the feature allocation profiling, as we still have it enabled from the log.

```auto
2023-02-08 01:40:15.595 UTC [000032c6] info [native] AllocationProfiling: enabled=Y

```

I’m not familiar with Java, could anyone give insight/resources on how this can be done? Checking on the command and Dynatrace no such options.

In addition they also suggested to replace the garbage collector from&nbsp;Shenandoah to G1, not sure how this is related. If anyone has suggestion on how to troubleshoot would be helpful.

Thank you.

---

<div class="post-metadata">

**Author:** ![Babar\_Qayyum](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/babar_qayyum/32/13620_2.png) [@Babar\_Qayyum](https://community.dynatrace.com/u/Babar_Qayyum)\
**Post date:** [March 21, 2023, 6:01am UTC](https://community.dynatrace.com/t/troubleshooting-memory-leak-from-oneagent-installed-on-the-server/38917/2 "2023-03-21T06:01:44Z")

</div>

Hello&nbsp;[@Ardhi](https://community.dynatrace.com/user/51035)

You can disable continuous memory profiling from the OneAgent features globally or can override on the particular process level.

> **[Memory profiling in Profiling & Optimization](https://docs.dynatrace.com/docs/observe/application-observability/profiling-and-optimization/memory-profiling)**
>
> Analyze memory allocation with Dynatrace.

Regards,

Babar

---

<div class="post-metadata">

**Author:** ![Ardhi](https://avatars.discourse-cdn.com/v4/letter/a/e99b99/32.png) [@Ardhi](https://community.dynatrace.com/u/Ardhi)\
**Post date:** [March 22, 2023, 9:03am UTC](https://community.dynatrace.com/t/troubleshooting-memory-leak-from-oneagent-installed-on-the-server/38917/3 "2023-03-22T09:03:02Z")

</div>

thank you. It’s too bad we can turn it off on host level
