Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8345493

JFR: JVM.flush hangs intermittently

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P3 P3
    • 24
    • 24
    • hotspot
    • None
    • jfr

      This is an umbrella bug for hangs related to jdk.jfr.internal.jdk.jfr.internal.JVM.flush()

      Typical thread dump looks like this:

      "MainThread" #34 [1203715] prio=5 os_prio=0 cpu=1856.25ms elapsed=1200.19s tid=0x0000ffffac4753f0 nid=1203715 waiting for monitor entry [0x0000ffff5c80d000]
         java.lang.Thread.State: BLOCKED (on object monitor)
      Thread: 0x0000ffffac4753f0 [0x125e03] State: _at_safepoint _at_poll_safepoint 0
         JavaThread state: _thread_blocked
          at jdk.jfr.internal.MetadataRepository.setSettings(jdk.jfr@24/MetadataRepository.java:243)
          - waiting to lock <0x000000011f9499d8> (a jdk.jfr.internal.MetadataRepository)
          at jdk.jfr.internal.PlatformRecorder.updateSettingsButIgnoreRecording(jdk.jfr@24/PlatformRecorder.java:393)
          at jdk.jfr.internal.PlatformRecorder.updateSettings(jdk.jfr@24/PlatformRecorder.java:382)
          at jdk.jfr.internal.PlatformRecorder.start(jdk.jfr@24/PlatformRecorder.java:252)
          - locked <0x000000011f80db28> (a jdk.jfr.internal.PlatformRecorder)
          at jdk.jfr.internal.PlatformRecording.start(jdk.jfr@24/PlatformRecording.java:127)
          - locked <0x000000011f80db28> (a jdk.jfr.internal.PlatformRecorder)
          at jdk.jfr.Recording.start(jdk.jfr@24/Recording.java:177)
          at jdk.jfr.tool.TestAssemble.main(TestAssemble.java:66)
          at java.lang.invoke.LambdaForm$DMH/0x0000ffff4c4083e0.invokeStatic(java.base@24/LambdaForm$DMH)
          at java.lang.invoke.LambdaForm$MH/0x0000ffff4c40ac10.invoke(java.base@24/LambdaForm$MH)
          at java.lang.invoke.Invokers$Holder.invokeExact_MT(java.base@24/Invokers$Holder)
          at jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(java.base@24/DirectMethodHandleAccessor.java:155)
          at jdk.internal.reflect.DirectMethodHandleAccessor.invoke(java.base@24/DirectMethodHandleAccessor.java:104)
          at java.lang.reflect.Method.invoke(java.base@24/Method.java:573)
          at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
          at java.lang.Thread.runWith(java.base@24/Thread.java:1589)
          at java.lang.Thread.run(java.base@24/Thread.java:1576)

      "JFR Recorder Thread" #35 [1203785] daemon prio=5 os_prio=0 cpu=3.19ms elapsed=1199.91s tid=0x0000fffefcf6d7e0 nid=1203785 runnable [0x0000000000000000]
         java.lang.Thread.State: RUNNABLE
      Thread: 0x0000fffefcf6d7e0 [0x125e49] State: _at_safepoint _at_poll_safepoint 0
         JavaThread state: _thread_in_native

      "JFR Periodic Tasks" #36 [1204201] daemon prio=5 os_prio=0 cpu=20.92ms elapsed=1198.94s tid=0x0000fffefd209ec0 nid=1204201 runnable [0x0000ffff5c60e000]
         java.lang.Thread.State: RUNNABLE
      Thread: 0x0000fffefd209ec0 [0x125fe9] State: _at_safepoint _at_poll_safepoint 0
         JavaThread state: _thread_blocked
          at jdk.jfr.internal.JVM.flush(jdk.jfr@24/Native Method)
          at jdk.jfr.internal.MetadataRepository.flush(jdk.jfr@24/MetadataRepository.java:382)
          - locked <0x000000011f9499d8> (a jdk.jfr.internal.MetadataRepository)
          at jdk.jfr.internal.periodic.FlushTask.execute(jdk.jfr@24/FlushTask.java:47)
          at jdk.jfr.internal.periodic.PeriodicTask.run(jdk.jfr@24/PeriodicTask.java:128)
          at jdk.jfr.internal.periodic.PeriodicEvents.doPeriodic(jdk.jfr@24/PeriodicEvents.java:175)
          at jdk.jfr.internal.PlatformRecorder.periodicTask(jdk.jfr@24/PlatformRecorder.java:518)
          at jdk.jfr.internal.PlatformRecorder.lambda$startDiskMonitor$0(jdk.jfr@24/PlatformRecorder.java:444)
          at jdk.jfr.internal.PlatformRecorder$$Lambda/0x000003f001076b08.run(jdk.jfr@24/Unknown Source)
          at java.lang.Thread.runWith(java.base@24/Thread.java:1589)
          at java.lang.Thread.run(java.base@24/Thread.java:1576)

            mgronlun Markus Grönlund
            egahlin Erik Gahlin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: