0

I'm not facing an actual issue yet, rather trying to avoid any...

Currently, these packages are installed on my PC (automatically installed during a fresh install of Kubuntu 14.04):

$ apt list openjdk* --installed
Listing... Done
**openjdk-6-jdk**/trusty-updates,trusty-security,now 6b36-1.13.8-0ubuntu1~14.04 amd64 [installed,automatic]
**openjdk-6-jre**/trusty-updates,trusty-security,now 6b36-1.13.8-0ubuntu1~14.04 amd64 [installed,automatic]
**openjdk-6-jre-headless**/trusty-updates,trusty-security,now 6b36-1.13.8-0ubuntu1~14.04 amd64 [installed,automatic]
**openjdk-6-jre-lib**/trusty-updates,trusty-security,now 6b36-1.13.8-0ubuntu1~14.04 all [installed,automatic]
**openjdk-7-doc**/trusty-updates,trusty-security,now 7u79-2.5.6-0ubuntu1.14.04.1 all [installed,automatic]
**openjdk-7-jre**/trusty-updates,trusty-security,now 7u79-2.5.6-0ubuntu1.14.04.1 amd64 [installed]
**openjdk-7-jre-headless**/trusty-updates,trusty-security,now 7u79-2.5.6-0ubuntu1.14.04.1 amd64 [installed]

May I safely leave these packages present on my PC and install Oracle JDK 8 from Oracle.com along with these older versions of Java?

And is there any recommendation regarding the installation directory for Oracle JDK 8?

Thank you in advance for your suggestions.

1
  • Hi again. As I was a bit impatient solving all the issues I've been facing over the past 24H trying to get a functional Eclipse or NetBeans installation (via Muon - absolute failure), I finally followed an online tutorial to install JDK 8u51 and NetBeans 8.0.2 which apparently succeeded brilliantly. In addition to setting the JAVA_HOME env. variable for my user environment (done), are there any other important tasks to perform to complete this JDK 8 installation? Thanks again.
    – Valdo
    Aug 13, 2015 at 16:41

1 Answer 1

1

Ok, everything went ok and here is how I did briefly:

  • I left OpenJDK 6&7 installed on my PC. Apparently no problem installing Oracle JDK8 along with them, in a dedicated directory. I only added these lines to my ~/.profile at the end of the whole installation process to be sure to be using JDK/JRE 8 at all times:

    export JAVA_HOME=/usr/local/bin/jdk1.8.0_51
    export PATH=$JAVA_HOME/bin:$PATH
    

Note: JAVA_HOME wasn't set previously.

  • followed tutorial http://www.tecmint.com/html5-mobile-web-development-using-netbeans-and-java/ to install JDK and NetBeans (adapted a bit to the most recent JDK/NetBeans releases and to my needs - no intention to develop HTML5 applications, so I downloaded the "Java SE" edition of NetBeans).

  • Installation directories I chose (I actually conformed to the tutorial):

    /usr/local/bin #for JDK.
    /usr/local #for NetBeans.
    

Addition:

Some time later I realized that double-clicking on a .jar file was still launching "OpenJDK Java 6 Runtime" (cautious-launcher %f /usr/bin/java -jar) by default.

So I added a new entry (later set as the preferred one) in KDE's File Association preferences, for known type "application > x-java-archive":

[Name = Oracle JDK 8 Runtime]  
[Command = cautious-launcher %f /usr/local/bin/jdk1.8.0_51/bin/java -jar] 

Note: as for existing entry "OpenJDK Java 6 Runtime", .jar applications will not be allowed to execute except if their Executable bit is set (to be set manually if needed) - refer to "cautious-launcher".

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .