HotSpot Mission Control Enable at Startup

The Java Flight Recorder (JFR) agent is shipped with many recent distributions of HotSpot Java. JFR neither ships with nor works with IBM Java nor IBM Semeru Runtimes.

  1. Stop the JVM
  2. Append the following JVM options:
    • WebSphere Liberty jvm.options:
      -XX:+FlightRecorder
      -XX:StartFlightRecording=name=jfr,filename=recording.jfr,settings=profile
      -XX:FlightRecorderOptions=defaultrecording=true,dumponexit=true,dumponexitpath=path
    • WAS traditional generic JVM arguments:
      -XX:+FlightRecorder -XX:StartFlightRecording=name=jfr,filename=recording.jfr,settings=profile -XX:FlightRecorderOptions=defaultrecording=true,dumponexit=true,dumponexitpath=path
  3. Start the JVM
  4. Reproduce the issue (at least 5 minutes worth because Mission Control is a sampling profiler)
  5. Gracefully stop the JVM (i.e. don't kill it)
  6. Gather *.jfr files from the working directory of the process. By default:
    • WebSphere Liberty: $LIBERTY/usr/servers/$SERVER/
    • WAS traditional: $TWAS/profiles/$PROFILE/

For details, see the Mission Control chapter.