RFR: 8354057: Odd debug output in -Xlog:os+container=debug on certain systems
David Holmes
dholmes at openjdk.org
Fri Apr 11 02:09:34 UTC 2025
On Wed, 9 Apr 2025 02:05:15 GMT, Thomas Fitzsimmons <duke at openjdk.org> wrote:
> The issue was a trailing newline in a message argument to:
>
>
> log_debug(os, container)(...)
>
>
> `log_debug` implicitly appends a newline to the message, so the extra newline resulted in empty lines in the trace output.
>
> The old vs new output on my `Alpine Linux v3.21` virtual machine is:
>
>
> --- tt-old-alpine-legacy.txt 2025-04-08 21:49:31.847415499 -0400
> +++ tt-new-alpine-legacy.txt 2025-04-08 21:48:51.486322068 -0400
> @@ -1,10 +1,8 @@
> [0.000s][trace][os,container] OSContainer::init: Initializing Container Support
> [0.000s][debug][os,container] Detected optional pids controller entry in /proc/cgroups
> [0.000s][debug][os,container] controller cpuset is not enabled
> -[ ]
> [0.000s][debug][os,container] controller memory is not enabled
> -[ ]
> [0.000s][debug][os,container] One or more required controllers disabled at kernel level.
> openjdk version "25-internal" 2025-09-16
> -OpenJDK Runtime Environment (fastdebug build 25-internal-adhoc.fitzsim.jdk-old)
> -OpenJDK 64-Bit Server VM (fastdebug build 25-internal-adhoc.fitzsim.jdk-old, mixed mode)
> +OpenJDK Runtime Environment (fastdebug build 25-internal-adhoc.fitzsim.jdk)
> +OpenJDK 64-Bit Server VM (fastdebug build 25-internal-adhoc.fitzsim.jdk, mixed mode)
>
>
> Regression-tested with:
>
>
> make exploded-test TEST="test/hotspot/jtreg/containers test/jdk/jdk/internal/platform/cgroup gtest:cgroupTest*"
Apologies, I completely misunderstood the problem here and thought that the value coming from the system had the extra newline.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24533#issuecomment-2795650073
More information about the hotspot-runtime-dev
mailing list