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

JVM does not detect that it runs in container and does not use container resource quotas #14266

Closed
MichaelNesterenko opened this issue Jan 12, 2022 · 3 comments

Comments

@MichaelNesterenko
Copy link

For some reason jvm does not detect container context and uses host resource quotas

Test command:

docker run -m 128m --rm --entrypoint sh adoptopenjdk/openjdk11-openj9:alpine -c "java -Xdump:java:events=vmstart -XX:MinRAMPercentage=20 -XX:MaxRAMPercentage=30 -XX:+UseContainerSupport -version && cat /java*"

Excerpt from the output:

1CICONTINFO    Running in container : FALSE

Full log output:
jvm-log.txt

@pshipton
Copy link
Member

Perhaps related to #14190 (comment)

@MichaelNesterenko
Copy link
Author

@pshipton, looks like it, there is another host which uses cgroups v1 and jvm correctly sizes heap there.

@pshipton
Copy link
Member

Thanks. I'm going to close this as a dup then.

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

No branches or pull requests

2 participants