OpenJDK JDK11 not having JMC- Java Mission Controller- FlightRecorder
Asked Answered
G

6

23

I was hoping JMC would be available with OpenJDK, JDK11 binaries as this has been opensourced from Java 11 by oracle, but could not locate this in Oracle and AdoptOpenJDK Java-11 binaries under bin folder. I have also tried this https://jdk.java.net/jmc/ as some article said its being releases separately. Does anyone know how to get JMC for OpenJDK-11.

Gonzalez answered 21/12, 2018 at 9:47 Comment(3)
For your next questions you'll get better answers faster if you accept one of the answers given.Incoercible
Some weeks ago the early access builds were available on the link you included in your question. For an unknown reason the binary builds has been removed. Hopefully they return soon...Pilgarlic
Binary builds are available for JMC 8, please see: jdk.java.net/jmc/8Kovrov
B
19

I am editing this answer since builds are now available, and have been available, from multiple vendors for quite some time. The list is available in the readme for the JMC GitHub repo:

https://github.com/openjdk/jmc

Don't forget to give the project a star if you like it! :)

Here is the original answer:

Normally the builds will be available here: https://jdk.java.net/jmc/

See http://hirt.se/blog/?p=1007 for more information on the new delivery format.

The builds have been (temporarily) pulled because a switch from the old javax.mail coordinates to the new coordinates at jakarta-ee has not yet gotten the proper third-party approval. A new build, with plenty of fixes and with all the approvals properly in place (or a revert of the change), should be along within the next few weeks.

Up until then it is possible (also not hard) to build JMC 7, by pulling the official JMC repo from here: https://hg.openjdk.java.net/jmc/jmc7/

You can also build and pull the mainline mirror from the inofficial GitHub repo: https://github.com/JDKMissionControl/jmc

For more information on building JMC, see: http://hirt.se/blog/?p=947 (or simply read the README.md in the repository root)

Good luck!

Bonkers answered 26/12, 2018 at 11:19 Comment(4)
Thanks @Bonkers for giving valuable link. Sorry I got delayed in checking responses. Actually I am particularly interested in JFR (Java Flight-Recorder, While checking one of Oracle article I noticed its being with released with open jdk binaries also: blogs.oracle.com/java-platform-group/…. While trying to find something similar in jdk/bin I could not locate this from jdk-11 binaries (Checked OracleOpenJDK and AdoptOpenJdk). Can you please suggest if we can access Flight-Recorder directly from jdk binaries ?Gonzalez
JDK Flight recorder and JDK Mission Control are two different things. JDK Flight Recorder is build into Oracle JDK 8+ and OpenJDK 11+. JDK Mission Control is what you use to visualize the recordings. If you read my blog (hirt.se/blog/?p=1007), and especially the linked blog that Aurelio and I wrote, I think it will become clear why we have the new delivery format.Bonkers
Since then months have passed and there are still no news about the builds.Nostomania
@KARASZIIstván, good news! hirt.se/blog/?p=1312 (published 2021-03-17)Kovrov
I
12

Since Java11, JMC is not part of the JDK any more. It is a separate project, as you already noticed.

https://www.oracle.com/technetwork/java/javase/11-relnote-issues-5012449.html

Incoercible answered 21/12, 2018 at 9:57 Comment(2)
Thanks @Incoercible but could not locate binaries for same.Gonzalez
You gave the link in your question. Nullpointer gave the link to jmc 6 in a link.Incoercible
A
5

Azul provides free, unsupported builds of Zulu Mission Control available for download at http://azul.com/products/zulu-mission-control

Builds are available for clients running Windows, Linux, and Mac OS X.

There are now binaries produced by Oracle as well:

https://jdk.java.net/jmc/

Alexaalexander answered 17/5, 2019 at 18:9 Comment(2)
is this software free for personal use?Vasilikivasilis
This what their FAQ says "Does Azul make community (i.e., free) builds of Zulu Mission Control available? Yes. Free, unsupported builds of Zulu Mission Control are available for download at azul.com/products/zulu-mission-control. Builds are available for clients running Windows, Linux, and macOS." azul.com/products/zulu-mission-control/zulu-mission-control-faqAlexaalexander
R
0

I believe they're still evaluating GitHub to moving to an independent repository with current progress being still under jmc7.

You can currently download standalone versions from Oracle's website for mission-control.

Resistencia answered 21/12, 2018 at 14:40 Comment(2)
I'd love to know where you found an actual download link on Oracle's site.Unscientific
@Unscientific Not sure if I remember that. But generally, google search would be the medium for me to explore.Resistencia
C
0

Update

JMC 8 available when compiling it from source. Here is a single command for linux users to build your own copy of jmc

mkdir ~/jmcToDelete && \
cd ~/jmcToDelete && \
git clone https://github.com/openjdk/jmc.git && \
cd jmc/releng/third-party && \
mvn p2:site && \
runJetty="mvn jetty:run" && \
bash -c "$runJetty &" && \
cd ~/jmcToDelete/jmc/core && \
mvn clean install && \
cd ~/jmcToDelete/jmc && \
mvn package -Dmaven.test.skip=true && \
kill $(jps | grep Launcher | awk '{print $1}') && \
sudo mkdir -p /opt/java/jmc && \
sudo tar xzf  $(find ~/jmcToDelete/jmc/target -name '*.jmc-linux*') -C /opt/java/jmc  && \
sudo ln -s  /opt/java/jmc/jmc   /usr/local/bin/jmc  && \
rm -rf ~/jmcToDelete

typing jmc in a terminal should start it.

Outdated

As stated by Hirt you can compile it from http://hg.openjdk.java.net/jmc The jmc available in jdk8 (v5.5) requires the special flags -XX:+UnlockCommercialFeatures -XX:+FlightRecorder to be present in the JVM process and it will not retrieve "flight records" if they are not there, so you can only use it with java1.8. If you would like to add those flags on openjdk-11 it will fail with Unrecognized VM option 'UnlockCommercialFeatures' meaning that you don't need them as they are enabled by default ( FlightRecorder ).

I compiled jmc-7.1.0 without issues by downloading the gz archive from http://hg.openjdk.java.net/jmc/jmc/ Follow the steps present in the README file: Make sure the compilation is done with jdk1.8 In one terminal :

cd releng/third-party
mvn p2:site
mvn jetty:run

And in the second terminal:

cd core
mvn clean install
cd ..
mvn package

On completion you should have all your artefacts in the target folder. The default jmc start script has a lot of flags present and it will not start with all of them, hence you can start the intended jar using

java -jar ./jmc-[...]/target/products/jmc/plugins/org.eclipse.equinox.launcher_[...].jar
Caine answered 8/5, 2019 at 16:7 Comment(0)
W
0

BellSoft provides Liberica Mission Control: https://bell-sw.com/pages/lmc/

As per their documentation, it's free to use in production environments, and there is a commercial support included as part of Support Subscription for Liberica JDK.

Waterish answered 28/10, 2019 at 11:26 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.