Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

High memory usage/leak #174

Open
vinc817 opened this issue Jul 7, 2024 · 16 comments
Open

High memory usage/leak #174

vinc817 opened this issue Jul 7, 2024 · 16 comments

Comments

@vinc817
Copy link

vinc817 commented Jul 7, 2024

This process is taking over 20% of the RAM:
/usr/local/openjdk-11/bin/java -Dsonarr.apikey=apikey -Dsonarr.baseUrl=http://192.168.2.150:8989/ -Dsonarr.qualityProfile=WEB-DL1080p -Dradarr.api can't read the rest of the process

Killing Watchlistarr (on Unraid) fixed it.

image

@ersan
Copy link

ersan commented Jul 14, 2024

I think this is the purpose of the -Xmx100m argument in the readme which you aren't using - to limit the program's memory usage.

@nylonee
Copy link
Owner

nylonee commented Jul 31, 2024

The -Xmx100 argument would indeed help, but your top is still worrying. I'll keep this thread open so that I can try this out myself when I'm back at a computer (I'll been afk for a while, perhaps until October)

@vinc817
Copy link
Author

vinc817 commented Aug 22, 2024

I think this is the purpose of the -Xmx100m argument in the readme which you aren't using - to limit the program's memory usage.

Thank you for both your replies. I am using Docker in Unraid. Where should I be able to enter this argument?
I also see this argument in my entrypoint.sh file:

CMD=("/app/bin/watchlistarr")

JAVA_OPTS=(-Xmx100m)

exec "${CMD[@]}" "${JAVA_OPTS[@]}"

@danimal1986
Copy link

@ersan @nylonee
Any update? I'm having the same issue as @vinc817 on unraid. I just noticed a very high memory usage and looking at htop i saw the exact same thing. Once i killed watchlistarr memory went back to normal.

@paulbaird87
Copy link

Same, Unraid reporting container using 3.2gb dedotated wam

@danimal1986
Copy link

seems like the update may have fixed it?

@vinc817
Copy link
Author

vinc817 commented Oct 23, 2024

seems like the update may have fixed it?

It hasn't fixed mine unfortunately. Still using lots of RAM.

@nylonee
Copy link
Owner

nylonee commented Oct 23, 2024

Thanks all for your comments, the latest build wouldn't have fixed this issue, as this looks like a real memory leak.

Out of curiosity, is everybody here who's getting the issue running on a java version that's less than version 21? (If you're running via docker, then the answer is yes I'm using version 11).

@danimal1986
Copy link

Thanks all for your comments, the latest build wouldn't have fixed this issue, as this looks like a real memory leak.

Out of curiosity, is everybody here who's getting the issue running on a java version that's less than version 21? (If you're running via docker, then the answer is yes I'm using version 11).

Docker, but no idea what Java version

@adamtiley
Copy link

adamtiley commented Oct 24, 2024

Also getting this issue, Docker on Unraid. 4GB's of RAM taken up but I've turned it off for now.

@Starminder
Copy link

Windows.

Exception in thread "io-compute-0" java.lang.OutOfMemoryError: Java heap space
at java.base/java.util.Arrays.copyOf(Arrays.java:3745)
at java.base/java.lang.AbstractStringBuilder.ensureCapacityInternal(AbstractStringBuilder.java:172)
at java.base/java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:538)
at java.base/java.lang.StringBuilder.append(StringBuilder.java:179)
at scala.collection.IterableOnceOps.addString(IterableOnce.scala:1252)
at scala.collection.IterableOnceOps.addString$(IterableOnce.scala:1241)
at scala.collection.AbstractIterator.addString(Iterator.scala:1300)
at scala.collection.IterableOnceOps.mkString(IterableOnce.scala:1191)
at scala.collection.IterableOnceOps.mkString$(IterableOnce.scala:1189)
at scala.collection.AbstractIterator.mkString(Iterator.scala:1300)
at scala.runtime.ScalaRunTime$._toString(ScalaRunTime.scala:156)
at scala.util.Right.toString(Either.scala:471)
at java.base/java.lang.String.valueOf(String.java:2951)
at java.base/java.lang.StringBuilder.append(StringBuilder.java:173)
at http.HttpClient.$anonfun$makeHttpRequest$7(HttpClient.scala:72)
at http.HttpClient$$Lambda$406/0x0000000100444040.apply(Unknown Source)
at cats.effect.IOFiber.succeeded(IOFiber.scala:1171)
at cats.effect.IOFiber.runLoop(IOFiber.scala:240)
at cats.effect.IOFiber.asyncContinueSuccessfulR(IOFiber.scala:1358)
at cats.effect.IOFiber.run(IOFiber.scala:113)
at cats.effect.unsafe.WorkerThread.run(WorkerThread.scala:721)
java.lang.OutOfMemoryError: Java heap space
at java.base/java.util.Arrays.copyOf(Arrays.java:3745)
at java.base/java.lang.AbstractStringBuilder.ensureCapacityInternal(AbstractStringBuilder.java:172)

@DHernan
Copy link

DHernan commented Nov 29, 2024

Same issue here. Good to know the memory limit command and I’ll check it out later. I’m using Docker for windows

@m33ts4k0z
Copy link

m33ts4k0z commented Dec 4, 2024

Hi.

Same for me when running Watchlistarr in a docker container on Unraid. The RAM usage is at 3GB but ramps up over time. Now sitting at 6GB.

@rustyserpent
Copy link

This is Still an issue with docker on Unraid.

@m33ts4k0z
Copy link

m33ts4k0z commented Dec 24, 2024

For all of you experiencing this on Unraid, adding this flag in the extra parameters field of the container will solve the issue: --memory=1G

It is now using about 400MB for over 2 weeks without noticing any impact on performance.

@bayramog
Copy link

Same issue at Unraid again. Limiting memory is only solution for now.

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests