Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/usr/lib/jvm/java-11-openjdk-amd64/bin seems to be no JDK! #122

Open
Mangonels opened this issue Jun 15, 2020 · 5 comments
Open

/usr/lib/jvm/java-11-openjdk-amd64/bin seems to be no JDK! #122

Mangonels opened this issue Jun 15, 2020 · 5 comments

Comments

@Mangonels
Copy link

Mangonels commented Jun 15, 2020

I have java jdk & jre installed on Ubuntu 20.04, and I added:
JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
to jvmtop.sh (line 10), as I saw in a tutorial.
Im asuming this counts as having a valid JDK environment path, but even if it doesn't, I already tried everything I mention here: https://askubuntu.com/questions/1248311/running-jvmtop-profile-the-java-home-environment-variable

However I get this message:
/usr/lib/jvm/java-11-openjdk-amd64/bin seems to be no JDK!
oddly enough, the path in the error seems to include bin, even though I only specified it up to java-11-openjdk-amd64.

I did nothing more and nothing less than what I mentioned. Am I missing something?

@Mangonels
Copy link
Author

Mangonels commented Jun 16, 2020

Got it to work by switching from java 11, to java 8.
But how do you exit the profiling mode?
Edit: well, I guess just disconnecing from ubuntu is one way.

@tangsaidi
Copy link

I can reproduce this problem using a Ubuntu machine with only Java 11 installed.

@tangsaidi
Copy link

This is likely because tools.jar was removed in JDK 9. Not sure if there's a fix to this problem.

@rgb1380
Copy link

rgb1380 commented Mar 23, 2022

I get the same problem with openjdk 17:
/Users/user01/Library/Java/JavaVirtualMachines/openjdk-17.0.2/Contents/Home seems to be no JDK!

There is no solution for this?

@Invertisment
Copy link

If I run any Java app with a newer version and run jvmtop on Java 8 I get this result:

These are IntelliJ and some Gradle processes running on Java11:

388753 inCompileDaemon [ERROR: Could not attach to VM] 
388828 inCompileDaemon [ERROR: Could not attach to VM] 
389039 inCompileDaemon [ERROR: Could not attach to VM] 
386926 ap.GradleDaemon [ERROR: Could not attach to VM] 
383163 ellij.idea.Main [ERROR: Could not attach to VM]

On Java 8 they look fine but IntelliJ probably runs on their own JDK:

391975 m.jvmtop.JvmTop   76m 7015m   22m   n/a  0.12%  0.00% O8U33   _   25   
390917 ap.GradleDaemon  597m 1820m  239m   n/a  0.06%  0.00% O8U33   _   37   
391314 inCompileDaemon  227m 1820m  135m   n/a  0.06%  0.00% O8U33   _   16   
391376 inCompileDaemon  174m 1820m  145m   n/a  0.00%  0.00% O8U33   _   15   
391256 inCompileDaemon  231m 1820m  154m   n/a  0.00%  0.00% O8U33   _   17   
392478 ellij.idea.Main [ERROR: Could not attach to VM]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants