visualvm fails to launch because it can't find jdk: "Cannot find java. Please use the --jdkhome switch"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
visualvm (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: visualvm
On a default installation of Ubuntu 10.10 the OpenJava JRE is installed. Install the Sun JDK from the Ubuntu repositories and the Java monitoring tool VisualVM is bundled with it. VisualVM requires a JDK and does not work with a JRE installation of Java. The launch script for VisualVM (/usr/bin/
line 13: for j in /usr/lib/
This line fails to find the Sun JDK but instead attempts to launch VisualVM using the OpenJava JRE. VisualVM fails to launch and presents a popup dialog asking for a valid JDK.
By switching the order of the "Sun" and "Open" paths in line 13 the problem is fixed and VisualVM loads correctly.
for j in /usr/lib/
The Ubuntu package is: visualvm version 1.3-0ubuntu2
Related branches
tags: | added: patch |
Changed in visualvm (Ubuntu): | |
status: | New → Confirmed |
I can confirm that I had the same issue on 10.10 and using the above solution worked.