one JVM only — how?

I had to install the Oracle JDK to get Netbeans to launch (forgot about umake).

Now that I have the official JVM, I want to remove each and every other JVM — all the OpenJDK stuff, including IcedTea, et. al.

Can I have “one Java” to rule them all? Partly, it just makes sense, and, partly, it’s a mild security concern. On Windows, I know that there were many problems with regards to version numbers and outdated JVM’s. As I recall, there was a notice to that effect for Ubuntu, too.

Answer

There are several ways to do this, some of them may lead to problems.

Remove OpenJDK the safe way by selecting everything yourself.

Check what is installed and what you want to remove.

Open a terminal and execute :

sudo dpkg --get-selections  

Select and purge the packages you want to remove.

Open a terminal and execute :

sudo apt-get purge <package>  

Example :

Removal of installed packages

openjdk-8-jdk:amd64
openjdk-8-jre:amd64
openjdk-8-jre-headless:amd64

sudo apt-get purge openjdk-8-jdk openjdk-8-jre openjdk-8-jre-headless

Attribution
Source : Link , Question Author : Thufir , Answer Author : cl-netbox

Leave a Comment