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

jvarkit docker container memory error #251

Open
molly-hetheringtonrauth opened this issue Jul 26, 2024 · 3 comments
Open

jvarkit docker container memory error #251

molly-hetheringtonrauth opened this issue Jul 26, 2024 · 3 comments

Comments

@molly-hetheringtonrauth

Subject of the issue

The docker container for the jvarkit software (https://hub.docker.com/r/lindenb/jvarkit) is throwing a memory error:
"There is insufficient memory for the Java Runtime Environment to continue.
Cannot create worker GC thread. Out of system resources."

Your environment

Running jvarkit through the docker container so the environment is the docker container.

Steps to reproduce

I ran the docker container interactively with:
docker run --rm -it -v $PWD:/my_data -u $(id -u):$(id -g) lindenb/jvarkit:1b2aedf24
and then ran this code from within the container:
java -jar /opt/jvarkit/dist/jvarkit.jar biostar84452 --samoutputformat BAM --output sample_name_clipped.bam sample_name_trimmed.sorted.bam

I am running the docker container on a virtual machine. I was able to run the command without issues locally on my machine but not through the docker container. I also tried increasing the memory of my VM to 30GB, but got the same error when trying to use the docker container.

I did not try to run the docker container with other commands as I am unfamiliar with those.

Expected behaviour

proceed with no error and create a bam file with hard clipped bases from reads.

Actual behaviour

Throws a memory error: "There is insufficient memory for the Java Runtime Environment to continue.
Cannot create worker GC thread. Out of system resources."

@lindenb
Copy link
Owner

lindenb commented Jul 27, 2024

hi,
please try to increase the JVM memory using the -Xmx flag :
java -Xmx10G -jar /opt/jvarkit/dist/jvarkit.jar biostar84452 ...

@molly-hetheringtonrauth
Copy link
Author

I tried your suggestion to use -Xmx10G flag, but that still did not work, but found a solution.

I was using docker version 19.03.12 (for ubuntu). I upgraded my docker version to 24.0.02 (for ubuntu) and jvarkit now runs using the docker container. Here is a related git issue: adoptium/temurin-build#3020. From the issue it sounds like there is a bug in older docker versions for interacting with java. (My coworker was using docker version 20. 10.21 and she could run jvarkit using the docker container just fine, so now sure which version of docker the bug was fixed).

@lindenb
Copy link
Owner

lindenb commented Jul 29, 2024

cool thank you for the feedback

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

2 participants