I'm trying to install JDK on ubuntu 14.04 LTS. I downloaded it from oracle website. Than I extracted it and moved in usr/lib/java. It says java doesn't exist but it does.    I use this video
1277
I want to install Oracle's JRE and to update to the latest version with the Software Updater when they released. Is there a Ubuntu package that is provided by Canonical or Oracle?  Before release Java 7, I followed  to install Java 6.  But it doesn't work for Java 7. There is no package sun-java7-xxx. How can you install Java 7?
16794
I installed Java JDK on Ubuntu 12.04 and added Java home to my path at ~/.bashrc:  export PATH=/opt/jdk1.7.0_40/jdk1.7.0_40/bin:$PATH   This looks a little bit strange but it's really my path.  After this I installed maven through:  sudo apt-get install maven   It installed all the needed libraries and now when I run mvn -version, I see:  Error: JAVA_HOME is not defined correctly.   We cannot execute /opt/jdk1.7.0_40/bin/java   What is wrong with it?   How to solve this trouble?
79193
I'm trying to run a jar application under Ubuntu, so I installed OpenJDK Java 7 Runtime, but when I open this application I got this message :     The file '/home/aimad/Programms/jMerise/JMerise.jar' is not marked as   executable.  If this was downloaded or copied from an untrusted   source, it may be dangerous to run.  For more details, read about the   executable bit.
87528
I am trying to install Matlab on Ubuntu 12.04, I have a 32bits machine. I downloaded the files and set the file install to exectable, then run :  $ ./install -v   but then I got the error :  Error : Cannot locate Java Runtime Environment (JRE). The directory /Unix_MAC/sys/java/jre/glnx86/jre does not exist.   So I decided to add the path of matlab's jre to the command ( But before I went to sys/java/jre/glnxa64/jre/glnxa64 and changed the file java to executable), then tried :  $ ./install -v -javadir /home/mbenseddik/Unix_MAC/sys/java/jre/glnxa64/jre/   But then I got the following error :  Preparing installation files ... cp: impossible d'évaluer «/home/mbenseddik/Unix_MAC/bin/glnx86/*»: No such file or directory -&gt;  DVD                 = /home/mbenseddik/Unix_MAC -&gt;  ARCH                = glnx86 -&gt;  DISPLAY             = :0.0 -&gt;  TESTONLY            = 0 -&gt;  JRE_LOC             = /tmp/mathworks_11294/sys/java/jre/glnx86/jre -&gt;  LD_LIBRARY_PATH     = /tmp/mathworks_11294/bin/glnx86       Command to run:  /tmp/mathworks_11294/sys/java/jre/glnx86/jre/bin/java -Xmx512m  -splash:"/home/mbenseddik/Unix_MAC/java/splash.png" -Djava.ext.dirs=/tmp/mathworks_11294/sys/java/jre/glnx86/jre/lib/ext:/tmp/mathworks_11294/java/jar:/tmp/mathworks_11294/java/jar/ja_JP/:/tmp/mathworks_11294/java/jar/zh_CN/:/tmp/mathworks_11294/java/jarext:/tmp/mathworks_11294/java/jarext/axis2/:/tmp/mathworks_11294/java/jarext/guice/:/tmp/mathworks_11294/java/jarext/webservices/ com/mathworks/professionalinstaller/Launcher -root "/home/mbenseddik/Unix_MAC" -tmpdir "/tmp/mathworks_11294"   Installing ... /tmp/mathworks_11294/sys/java/jre/glnx86/jre/bin/java: 1: /tmp/mathworks_11294/sys/java/jre/glnx86/jre/bin/java: Syntax error: "(" unexpected Finished   It seems like it is looking for glnx86 whereas the only directory inside the sys/java/jre directory is glnx64...  Any idea on the matter ?
37515
I have a Java project in Eclipse that requires Java 7 running in 32 bit mode. I tried to force running in 32 bit mode by adding the flag -d32 to the VM arguments.  However, I then get the following message:  Error: This Java instance does not support a 32-bit JVM. Please install the desired version.   I tried the same with Java 6, and there the flag works. So I supposed that I don't have a 32 bit version of Java installed. I checked all installed versions of java with /usr/libexec/java_home -V and get the following list:  1.7.0_75, x86_64:   "Java SE 7" /Library/Java/JavaVirtualMachines/jdk1.7.0_75.jdk/Contents/Home 1.7.0_67, x86_64:   "Java SE 7" /Library/Java/JavaVirtualMachines/jdk1.7.0_67.jdk/Contents/Home 1.6.0_65-b14-466.1, x86_64: "Java SE 6" /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home 1.6.0_65-b14-466.1, i386:   "Java SE 6" /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home   I then run the same command with the -d32 flag to check for 32 bit VMs and get the following list:  1.6.0_65-b14-466.1, i386:   "Java SE 6" /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home   So it really seems that there is no Java 7 with is compatible to run in 32bit mode available on my system. I checked the Internet, but couldn't find a way how to install 32 bit Java on a Mac. It always is assumed that the -d32 switch is working. My Mac is running Yosemite (10.10.2).  So what am I doing wrong? Is there a step for step tutorial that I can follow to run my application in Eclipse in 32bit mode with Java 7.
38745
I have installed both OpenJDK 6 and 7. When I run "java somefile" from the command line, OpenJDK 6 is invoked. I do not want to change this default behavior. What command can I use to run my non-default OpenJDK 7 installation instead?  (I am used to running "python somefile" to invoke the default Python, "python2.7 somefile" to use Python 2.7 specifically and "python3 somefile" to use Python 3 specifically.)
22253
Chrome refused to run a java app unless i upgraded to .45, which I did my dling the installer from oracle.  Java 7 u45.  Installer said it worked.  Chrome still won't start java.    $ which java /usr/bin/java  $ java -version java version "1.7.0_06" Java(TM) SE Runtime Environment (build 1.7.0_06-b24) Java HotSpot(TM) 64-Bit Server VM (build 23.2-b09, mixed mode) ~/private/WDI/git🍔     I may be easily fooled, but that doesn't say "45" anywhere.  (Yes, "06", and "24" and "23.2-b09", but nary a 45.  Such numbers!)  Anybody know if this is u45, or where the installer placed it?  UPDATE: there is a Java System Preference Panel that says "Your system has the recommended version of Java: Java 7 Update 45."  Still, Chrome doesn't appear to see it.
61721
Apparently, I have OpenJDK 6 JRE (openjdk-6-jre 6b27-1.12.6-1ubuntu0.12.04.2) and 7 JRE (openjdk-7-jre 7u25-2.3.10-1ubuntu0.12.04.2) installed in parallel – I don't know why I have both of them, I can't remember installing any of them manually.  However, the Firefox Java plugin is occasionally reported to be out of date by some websites, and it seems to me that it relies on JRE 6. How can I make Firefox use the newer version? Removing JRE 6 seems like a bad idea; when I attempted to do so in synaptic it appeared to me that a lot of software still relies on the older JRE, since removing it would have removed programs like jedit as well.  Do I mix up stuff? I'm not even sure how the FF plugin interferes with the OpenJDK JRE's.  EDIT:  Having tried even more, the problem persists. Using update-alternatives --config java, I see that the default Java version (with status "manual mode") is already set to Java 7, and java -version returns "1.7.0_25". The file /usr/lib/jvm/java-7-openjdk-i386/jre/lib/i386/IcedTeaPlugin.so exists, but still Firefox shows the Java 6 plugin when looking at about:plugins.  To sum it up:  How do I make Firefox use the IcedTea plugin belonging to the default Java version?
23089
This may sound like a stupid question. Where are the core class files from Sun, like Button.class, located in the JDK installation folder C:\Program Files\Java\jdk1.5.0_12?   Or do the class files reside in C:\Program Files\Java\jre1.5.0_12 folder?
92850
Icedtea-7-plugin installed but it does not appears in the list in about:plugins in Chromium.  Not able to execute java applets.  Tried installing Icedtea-7-plugin but in vain. Using openjdk7 in 14.04
82102
I have installed JDK 6, but I can't execute a Java program.   For example, I have made test.java.  I compile it with javac tes.java and there's no error when I compile it, but when I want to execute that program it always displays an error.  I execute the Java program with java tes.  Exception in thread "main" java.lang.UnsupportedClassVersionError: tes : Unsupported major.minor version 51.0     at java.lang.ClassLoader.defineClass1(Native Method)     at java.lang.ClassLoader.defineClass(ClassLoader.java:634)     at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)     at java.net.URLClassLoader.defineClass(URLClassLoader.java:277)     at java.net.URLClassLoader.access$000(URLClassLoader.java:73)     at java.net.URLClassLoader$1.run(URLClassLoader.java:212)     at java.security.AccessController.doPrivileged(Native Method)     at java.net.URLClassLoader.findClass(URLClassLoader.java:205)     at java.lang.ClassLoader.loadClass(ClassLoader.java:321)     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)     at java.lang.ClassLoader.loadClass(ClassLoader.java:266) Could not find the main class: tes. Program will exit.   My javac version is 1.7.0, my java version is 1.6.0.  Here is my tes.java code:  class tes{      public static void main(String[]args){         System.out.println("hello");         }     }
108432
I'm trying to launch java:  $ java -version java: error while loading shared libraries: libjli.so: cannot open shared object file: No such file or directory  $ ldd /usr/lib/jvm/java-6-openjdk/jre/bin/java         linux-gate.so.1 =&gt;  (0xb779f000)         libz.so.1 =&gt; /usr/lib/libz.so.1 (0xb7780000)         libpthread.so.0 =&gt; /lib/i686/cmov/libpthread.so.0 (0xb7767000)         libjli.so =&gt; /usr/lib/jvm/java-6-openjdk/jre/bin/../lib/i386/jli/libjli.so (0xb7762000)         libdl.so.2 =&gt; /lib/i686/cmov/libdl.so.2 (0xb775e000)         libc.so.6 =&gt; /lib/i686/cmov/libc.so.6 (0xb7603000)         /lib/ld-linux.so.2 (0xb77a0000 $ ls /usr/lib/jvm/java-6-openjdk/jre/bin/../lib/i386/jli/ libjli.so   But java works under root:  $ sudo java -version java version "1.6.0_18" OpenJDK Runtime Environment (IcedTea6 1.8.7) (6b18-1.8.7-2~lenny1) OpenJDK Client VM (build 14.0-b16, mixed mode, sharing)   UPD:  /usr/lib/jvm/java-6-openjdk/jre/bin/java is actually my java command:  $ type java java is hashed (/usr/bin/java) $ ls -l /usr/bin/java lrwxrwxrwx 1 root root 22 Jul 14 10:15 /usr/bin/java -&gt; /etc/alternatives/java $ ls -l /etc/alternatives/java lrwxrwxrwx 1 root root 40 Jul 14 10:36 /etc/alternatives/java -&gt; /usr/lib/jvm/java-6-openjdk/jre/bin/java   UPD2:  I've also tried to set root PATH:  $ sudo su # echo $PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin # exit $ export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin $ java -version java: error while loading shared libraries: libjli.so: cannot open shared object file: No such file or directory   UPD3:  I'm tried:  # comm -3 &lt;(declare | sort) &lt;(declare -f | sort)   under root. But there is no usable environment variables for java.  UPD4:  strace -f java -version result:
92218
I've updated to Java 8 update 31 x64 on my OS X Mavericks (10.9.5) and now it will no longer work in my Chrome version 42.0.2288.6 dev. Why is this? It worked prior to updating.  I've tried the  and Chrome then claims that Java is not installed.  Java works in Firefox FWIW.
109961
I use ArchLinux, and an IDE called PyCharm. On its , it recommends using Java 6 instead of OpenJDK. ArchLinux has an OpenJDK package (jdk7-openjdk) that I have installed, installed, and from what I had read in the , it should be possible to install Oracle Java 6 along side OpenJDK 7 via a packages called jdk6-compat and jre6-compat, which install these versions of Java in /opt/ instead of the normal location.  However, after installing jdk6-compat and jre6-compat, I still see that I am running OpenJDK 7 when I run the following:  % java -version java version "1.7.0_09" OpenJDK Runtime Environment (IcedTea7 2.3.3) (ArchLinux build 7.u9_2.3.3-1-x86_64) OpenJDK 64-Bit Server VM (build 23.2-b09, mixed mode)   ...even after I have set JAVA_HOME and added /opt/java6/bin to my PATH in my .zshrc file.  How can I get PyCharm (or other applications) to use Oracle Java 6 instead of OpenJDK?  Thanks, and apologies if I've posted in the wrong place.  Other information that might be helpful:   Using Gnome 3 as DE
21133
I am a novice user and I am trying to install Oracle Java. The process calls for me to access /usr/local/java, but here is the problem. I get as far as /usr/local, then this is the message I get:  leonard@leonard-MT6452:/usr/local$ dir bin  etc  games  include  java  lib  man  sbin  share  src  leonard@leonard-MT6452:/usr/local$ cd /java/ bash: cd: /java/: No such file or directory  leonard@leonard-MT6452:/usr/local$ rm -r ~/java rm: cannot remove ‘/home/leonard/java’: No such file or directory   Help?
52399
What all needs to be done to install Android SDK / ADT Bundle on Ubuntu?  Each of the steps in the answer was found on some different forum as I encountered obstacles getting started with my Android SDK and posted questions in appropriate forums thereafter. So I thought this would be useful in that it is a one stop solution available, in case one ever needs to re-install Ubuntu and install the Android SDK / ADT Bundle from scratch!
115997
Only openjdk-11-jdk and newer seem to be available. Is there any way to install the OpenJDK 8? Preferably without adding a PPA.