Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I install freemind from USC Ubuntu 12.04, but it failed to run with the following error:


[warning] /usr/bin/freemind: No java runtime was found
[error] /usr/bin/freemind: Unable to find an appropriate java runtime. See java_wrappers(7) for help"

OpenJDK Java 6 runtime was installed.

share|improve this question
up vote 3 down vote accepted

Run update-alternatives --config java and make sure you configure it correctly.

Run java -version in a terminal and see the output.

From freemind web:

Freemind may not work with OpenJDK. I would recommend installing Sun/Oracle JRE/JDK.

A simple way of installing it on Ubuntu (build .deb packages from OTN binaries and set up a local repository, use apt-get to install;-) Check it out here:

share|improve this answer
I did the update-aternatives --config java, and choose /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java 1061 auto mode It fixed the problem! – Husni Nov 15 '12 at 7:29
Cool, good to see it work:-) – Terry Wang Nov 15 '12 at 12:03
If there is only one Java installed on the system, and this is the current Oracle Java 8, the above wont help. -- Have a look at my answer below – minni Aug 20 '15 at 21:10

The above did not work for me on Ubuntu 12.04/GNOME Shell with FreeMind 0.9.0 installed from the Ubuntu repository, this set up:

[warning] /usr/bin/freemind: No java runtime was found
[error] /usr/bin/freemind: Unable to find an appropriate java runtime. See java_wrappers(7) for help

java -version
java version "1.7.0_10"
Java(TM) SE Runtime Environment (build 1.7.0_10-b18)
Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)

sudo update-alternatives --config java
There are 2 choices for the alternative java (providing /usr/bin/java).

  Selection    Path                                     Priority   Status
* 0            /usr/lib/jvm/java-7-oracle/jre/bin/java   12        auto mode
  1            /usr/lib/jvm/java-7-oracle/bin/java       4         manual mode
  2            /usr/lib/jvm/java-7-oracle/jre/bin/java   12        manual mode

Press enter to keep the current choice[*], or type selection number: 0

whereis java
java: /usr/bin/java /usr/bin/X11/java /usr/share/java /usr/share/man/man1/java.1.gz
ls -l /usr/bin/java
lrwxrwxrwx 1 root root 22 May 16  2012 /usr/bin/java -> /etc/alternatives/java

Actual Path:
ls -l /usr/lib/j*
total 20
-rwxr-xr-x 1 root root 1033 Apr  2  2011 get-classpath
-rw-r--r-- 1 root root 9122 Jan 12 15:42
-rw-r--r-- 1 root root 2302 Jan 12 15:41

total 4
lrwxrwxrwx 1 root root   26 Sep  6 11:56 default-java -> /usr/lib/jvm/java-7-oracle
drwxr-xr-x 8 root root 4096 Dec 13 12:37 java-7-oracle

"/usr/lib/java-wrappers/" has the below setting, which is correct path.

#va-wrappers(7) default runtime

The 2 error are coming from /usr/lib/java-wrappers/, which doesn't seem to be loading the below from within it's file.

# Import the list of JVMs
. /usr/lib/java-wrappers/

I changed it to,


but it did not work.


This is what worked after trial and error by adding the below in the /usr/lib/java-wrappers/ file, under where it is trying to find,

if [ -z "$JAVA_HOME" ]; then, at line 90 in vi for me.

        # Added 2013-01-12 not being found from jvm-list

I commented out DIRS="" variable and changed it to




Both of them worked.

share|improve this answer

If anyone has the Problem in Ubuntu 15.04 with the newest Oracle Java 8 (and has not installed any other Open JDK), I found the problem in java-wrappers file which determines the available Java installations:

In file "/usr/lib/java-wrappers/":

=> added /usr/lib/jvm/java-8-oracle on line 35

__jvm_oracle8="/usr/lib/jvm/java-8-oracle /usr/lib/jvm/jdk-8-oracle-* /usr/lib/jvm/jre-8-oracle-*"

As the current installation of Oracle 8 Java is installed in this added path.

share|improve this answer
For me it was just __jvm_oracle8="/usr/lib/jvm/java-8-oracle-*" and I am on 14.04 – Vladislav Ivanishin Oct 7 '15 at 13:03

For me, the method "sudo update-alternatives --config java" do not work. I find a solution on an official website of linux developers.

The original link:

In short, you can try export JAVA_CMD=/usr/bin/java in Terminal.

You can put this command into system environment variables by creating the file "/etc/profile.d/" with the content :

export JAVA_CMD=/usr/bin/java
share|improve this answer

Ok, I found a more simple answer. I am running Ubuntu 14.04, off a fresh install (installed last night). I dropped in Oracle Java 8 using the instructions found here: Install Oracle 8 Java in Ubuntu

Then I installed Freemind from the software center and got the exact error in the originating post. To fix the problem I did this:

I edited the following file AS ROOT (but you can use your editor of choice, gedit works just fine if you want):

sudo vim /usr/bin/freemind

I added this line before the first "if" statement (for me line 18, but yours may be different)

export JAVA_CMD=/usr/bin/java

Now when I click on the Freemind Icon in Unity it works.


share|improve this answer

for Sun Java 1.6

change file /usr/lib/java-wrappers/

update following entry:

__jvm_sun6="/usr/lib/jvm/java-6-sun /usr/lib/j2*1.6-sun"


__jvm_sun6="/usr/lib/jvm/java-6-oracle /usr/lib/j2*1.6-oracle"
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.