Sun java or openjdk

Ubuntu – What’s the difference between OpenJDK and Sun Java for the end user?

Want to improve this question? Update the question so it focuses on one problem only by editing this post.

For users running Java application or applets in the browser, what difference does it make running either Sun Java or OpenJDK?

Oracle will be retiring the DLJ, and basing the proprietary implementation on OpenJDK. Can we expect similar experience in running Java apps using either OpenJDK or Oracle JDK?

Best Answer

Suns JDK is much faster for many applications using advanced graphic capabilities (2d and 3d), to the point that some applications are actually not usable using openjdk. See eg:

If I download the .tar.gz version of SweetHome3D (including the Sun JRE 1.6.0_20), the performance is excellent : moving inside the 3D view is smooth and easy to use If I launch it with Java Web Start (the one that comes with icedtea6-plugin package, that launches it under OpenJDK version 6b18-1.8-4ubuntu3), the 3D view is extremely slow, and unuseable.

Ubuntu – the difference between the five versions of Java on this page for Ubuntu

Are they all different versions of JDK? If not, then what?

They are different implementations of Java/development kits for Java (JDK). Java is a standard platform, and all of these implement that platform in their own way. Of these:

  • OpenJDK and GNU Compiler are the only ones that are open source. I usually prefer them — the ease of installation ( apt-get or Software Center) is a big factor.
    • OpenJDK in particular is derived mostly from the «official» Java source code that Oracle/Sun open sourced; it is backed by Oracle.
    • The 6 and 7 refer to versions of the language/platform. 7 is newer and has more features, but has been tested less; 6 is extremely mature and stable. I’d prefer 6 if you are just starting out.

    If you are starting out in programming, almost any of these will be a good fit. Go for OpenJDK just because its easy to install.

    The only experience I have in differentiating these is compiling in a low-resource environment (128-192MB RAM — a VPS); I found Oracle Java 6 JDK worked best for one program (i.e succeeded) and IBM Java 6 JDK for another.

    Ubuntu – IcedTea-8 cannot run any jnlp application (maybe due to openjdk-11?)

    After some trial and error I found only one useful solution — we need to install normal OpenJDK 8 from previous Ubuntu 16.04 LTS manually with commands below. It is usually not recommended, but we do not have other methods with positive result.

    So the commands to install are the following (we remove existing OpenJDK and then install deb-packages manually):

    sudo apt purge oracle-java11-* -y sudo apt purge *openjdk* -y sudo apt autoremove --purge -y wget http://archive.ubuntu.com/ubuntu/pool/main/o/openjdk-8/openjdk-8-jre-headless_8u272-b10-0ubuntu1~16.04_amd64.deb sudo apt install -y ./openjdk-8-jre-headless_8u222-b10-1ubuntu1~16.04.1_amd64.deb wget http://security.ubuntu.com/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb sudo apt install -y ./libpng12-0_1.2.54-1ubuntu1.1_amd64.deb wget http://archive.ubuntu.com/ubuntu/pool/main/o/openjdk-8/openjdk-8-jre_8u272-b10-0ubuntu1~16.04_amd64.deb sudo apt install -y ./openjdk-8-jre_8u222-b10-1ubuntu1~16.04.1_amd64.deb wget http://archive.ubuntu.com/ubuntu/pool/universe/i/icedtea-web/icedtea-netx-common_1.6.2-3ubuntu1_all.deb sudo apt install -y ./icedtea-netx-common_1.6.2-3ubuntu1_all.deb wget http://archive.ubuntu.com/ubuntu/pool/universe/i/icedtea-web/icedtea-netx_1.6.2-3ubuntu1_amd64.deb sudo apt install -y ./icedtea-netx_1.6.2-3ubuntu1_amd64.deb 

    Also we need to pin/hold the versions of such packages with single long command below:

    and then the application will run with

    javaws StartProRealTime.jnlp 

    Notes: the installation of Oracle Java 11 or 12 does not help either.

    Источник

    Thread: OpenJDK or Sun Java

    HappyLinux is offlineWay Too Much Ubuntu

    OpenJDK or Sun Java

    OK, I’m a little confused and would like some clarification.

    You typically have Sun Java Runtime Environment, the current being Version 6 Update 23. However, Ubuntu 10.10 comes with something called OpenJDK.

    After it took me a long time to finally get Sun Java Runtime Environment Version 6 Update 21 installed (cannot install the newest version for some odd reason), I find out that OpenJDK does the same stuff.

    Is there any difference between the two?
    Do I remove one or the other? Or keep them both?

    lykeion is offline100% Pure Ubuntu

    Re: OpenJDK or Sun Java

    For the end-user there is no difference, and technically the difference is very small, ~99% of their code is shared. For a Java developer OpenJDK will give you new features faster, whereas Sun JDK should give you more stability. I’d say that the main difference is that OpenJDK is open source and Sun Java is licenced.

    You can have both installed and use update-java-alternatives command to switch between them.

    And I shouldn’t worry about getting the latest u23 version of Sun Java, this is what Oracle (who own Sun Java now) say themselves on the release notes:

    Java SE 6u23 does not contain any additional fixes for security vulnerabilities to its previous release, Java SE 6u22. Users who have Java SE 6u22 have the latest security fixes and do not need to upgrade to this release to be current on security fixes.

    The current version of Sun Java in the Ubuntu Partner repository is 6u22. I don’t know how you got 6u21 installed.

    gradinaruvasile is offlineCake for coffee’s sake

    Re: OpenJDK or Sun Java

    99% ? I had problems running Sip Communicator, Mucommander and other smaller java apps on OpenJdk (almost all of them). Many dont even start.

    lykeion is offline100% Pure Ubuntu

    Re: OpenJDK or Sun Java

    @gradinaruvasile
    Tried running both programs you mentioned (muCommander, SIP Communicator) using OpenJDK without any problems.

    Attached Images

    Attached Images

    • muCommander.jpg (75.2 KB, 14 views)
    • sip-coommunicator.jpg (60.2 KB, 15 views)

    HappyLinux is offlineWay Too Much Ubuntu

    Re: OpenJDK or Sun Java

    QuoteOriginally Posted by lykeion View Post

    For the end-user there is no difference, and technically the difference is very small, ~99% of their code is shared. For a Java developer OpenJDK will give you new features faster, whereas Sun JDK should give you more stability. I’d say that the main difference is that OpenJDK is open source and Sun Java is licenced.

    You can have both installed and use update-java-alternatives command to switch between them.

    And I shouldn’t worry about getting the latest u23 version of Sun Java, this is what Oracle (who own Sun Java now) say themselves on the release notes:

    The current version of Sun Java in the Ubuntu Partner repository is 6u22. I don’t know how you got 6u21 installed.

    I had to manually insert a repository for it. Not sure whether it’s the correct one, but it’s the only one I could find after an hours googling. You’ll find the source list I have in the attached screen shot.

    Attached Images

    Attached Images

    • sources.jpg (54.9 KB, 16 views)

    Источник

    Thread: Should I use openjdk or sun-java-jdk?

    dixon is offlineGee! These Aren’t Roasted!

    Should I use openjdk or sun-java-jdk?

    Is openjdk a full impletation of sun-java-jdk? I’m a junior java programmer. Can I run into some issues using openjdk like incompatibility with sun-java-jdk? Mostly I develop desktop applications(used mostly in win) and webpages using mvc frameworks. So the final question is — are there any drawbacks of using openjdk?

    jespdj is offlineI Ubuntu, Therefore, I Am

    Join Date Jun 2006 Location The Netherlands Beans 2,185 —> Beans 2,185 Distro Ubuntu 12.04 Precise Pangolin

    Re: Should I use openjdk or sun-java-jdk?

    OpenJDK is the open source version of Sun’s JDK, but it isn’t 100% complete yet.

    If you are running 64-bit Ubuntu and you want a Java browser plug-in (to run Java applets in your browser), then use OpenJDK, because the 64-bit version of Sun Java 6 doesn’t include a browser plug-in.

    Otherwise, if you don’t really need applet support, you could use either Sun JDK 6 or OpenJDK. For most things, OpenJDK should work fine at the moment.

    Note, you can also install both Sun Java 6 and OpenJDK. With the following command you can choose which Java should be used as the default Java on your system:

    sudo update-alternatives --config java

    Источник

    What’s the difference between OpenJDK and Sun Java for the end user?

    Suns JDK is much faster for many applications using advanced graphic capabilities (2d and 3d), to the point that some applications are actually not usable using openjdk. See eg:

    If I download the .tar.gz version of SweetHome3D (including the Sun JRE 1.6.0_20), the performance is excellent : moving inside the 3D view is smooth and easy to use If I launch it with Java Web Start (the one that comes with icedtea6-plugin package, that launches it under OpenJDK version 6b18-1.8-4ubuntu3), the 3D view is extremely slow, and unuseable.

    Solution 2

    There is no difference except for those applications which don’t work properly with the OpenJDK.

    Java -JDK-16-Training OpenJDK Vs Oracle Java (Part 1)

    Which Java version is best to use ? Java 8 or 11 or 15 | Oracle JDK or OpenJDK or Zulu | LTS

    Which Version of the Java Development Kit Should You Install & Do You Need to Pay for It?

    Which Java to install? AdoptopenJDK? OpenJDK? Oracle Java? Corretto?

    Bài 39: Phân biệt JDK JRE JVM trong Java

    Oxwivi

    Updated on September 18, 2022

    Comments

    For users running Java application or applets in the browser, what difference does it make running either Sun Java or OpenJDK? EDIT Oracle will be retiring the DLJ, and basing the proprietary implementation on OpenJDK. Can we expect similar experience in running Java apps using either OpenJDK or Oracle JDK?

    I believe that’s about graphics performance (said to be lower in OpenJDK, Eclipse is said to be faster with Sun JDK), lack (or a replacement of a kind, meaning non-usual, which will raise compatibility issues) of patented (like some graphics, encryption, compression etc algos), 3-rd-party-copyrighted and restricted (like strong encryption) features implementation in OpenJDK. And I will definitely celebrate if upcoming Linux port of Java FX 2.0 will work properly with OpenJDK and be available through the repos.

    Close voters: Please check the date of this question. We are not meant to close questions from 2011, as this type was acceptable then.

    @Zacharee1, frankly, I want to close it because I don’t want any of my questions unanswered, and there’s no satisfactory answers to be found.

    @Oxwivi this question is technically «answered» according to the system. Any answer with at least 1 upvote qualifies it. But if you want it closed, well there you go.

    Yes, applications not working with OpenJDK is the difference. Why does it not work, what’s the difference?

    OpenJDK is a re-implementation of Sun’s JDK, as any re-implementation of such a large software there are differences, either because of bugs or different decisions regarding certain behaviors. I don’t have a link for those bugs, I know they are bring worked, but at this time it is known that are many websites wick work with sun’s jdk and not with the openjdk.

    guptarahul275

    So the obvious next question is: is one better than the other? And since Sun’s JDK is being dropped from the repositories (according to a number of websites, e.g. here: webupd8.org/2011/09/how-to-install-oracle-java-7-jdk-in.html‌​), leaving the OpenJDK available, is it worth it to get and install the Sun JDK?

    «Better» is a subjective term, from a compatibility standpoint Sun’s JDK is better, a large number of applications are developed and tested only with Sun’s JDK, however if your users can work with openjdk it’s always preferable to use the open source version.

    Yes, I’ve heard of the retirement of DLJ as well. Since Oracle Java is now going to be based on OpenJDK, how will they differ?

    Источник

    Читайте также:  Enumerate что делает python
Оцените статью