[jdk21u-dev] RFR: 8261242: [Linux] OSContainer::is_containerized() returns true when run outside a container

Jan Kratochvil jkratochvil at openjdk.org
Wed Apr 16 10:39:25 UTC 2025


A patch 3 of 6 for: [[21u] Backport intention of 8322420: [Linux] cgroup v2: Limits in parent nested control groups are not detected](https://mail.openjdk.org/pipermail/jdk-updates-dev/2025-April/043206.html)

It has a patch dependency on PR 2 of 6: https://github.com/openjdk/jdk21u-dev/pull/1660

This backport is clean. But it contains an additional oneliner (by Yuri Nesterenko):

make/data/hotspot-symbols/symbols-linux:
+JVM_IsContainerized

as otherwise the build would fail with:

src/java.base/linux/native/libjava/CgroupMetrics.c:42:(.text+0x11): undefined reference to `JVM_IsContainerized'

This oneliner was not needed in JDK24 as there is [JDK-8017234: Hotspot should stop using mapfiles](https://bugs.openjdk.org/browse/JDK-8017234).

-------------

Depends on: https://git.openjdk.org/jdk21u-dev/pull/1660

Commit messages:
 - 8261242: [Linux] OSContainer::is_containerized() returns true when run outside a container
 - src/java.base/linux/native/libjava/CgroupMetrics.c:42:(.text+0x11): undefined reference to `JVM_IsContainerized'

Changes: https://git.openjdk.org/jdk21u-dev/pull/1661/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk21u-dev&pr=1661&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8261242
  Stats: 411 lines in 20 files changed: 306 ins; 78 del; 27 mod
  Patch: https://git.openjdk.org/jdk21u-dev/pull/1661.diff
  Fetch: git fetch https://git.openjdk.org/jdk21u-dev.git pull/1661/head:pull/1661

PR: https://git.openjdk.org/jdk21u-dev/pull/1661


More information about the jdk-updates-dev mailing list