Tag Info

Hot answers tagged

98

There are several implementations of Java, the 3 most common implementations when talking about it for Ubuntu are: OpenJDK: The primary goal of the OpenJDK project is to produce an open-source implementation of the Java SE Platform (6 and 7). This is the default version of Java that Ubuntu uses and is the easiest to install. Sun Java: Sun Java is the ...


80

Remove all the Java related packages (Sun, Oracle, OpenJDK, IcedTea plugins, GIJ): sudo apt-get update apt-cache search java | awk '{print($1)}' | grep -E -e '^(ia32-)?(sun|oracle)-java' -e '^openjdk-' -e '^icedtea' -e '^(default|gcj)-j(re|dk)' -e '^gcj-(.*)-j(re|dk)' -e 'java-common' | xargs sudo apt-get -y remove sudo apt-get -y autoremove Purge config ...


50

Alternate install Java for Chrome, can also install icedtea: sudo apt-get install icedtea-7-plugin Then link icedtea in to chromium plugin folder thusly cd /usr/lib/chromium-browser/plugins and link sudo ln -s /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/amd64/IcedTeaPlugin.so


44

Installing OpenJDK is not enough for enabling Java in browsers. You'll also need to install the icedtea-7-plugin package: A restart of the browser might be required.


42

If you are using Debian Jessie (or Ubuntu 13.10+), try sudo apt-get install lib32stdc++6


38

Switching between installed Java versions can be accomplished using the update alternatives command. To get a list of your installed Java platforms, run the following command from the terminal: sudo update-alternatives --config java This will give you a list output similar to this: There are 2 choices for the alternative java (providing /usr/bin/java). ...


37

This guide (Which took me a little over 3 days to write and test) was made to solve most problems regarding the correct installation of Minecraft. It is very thorough and oriented for Ubuntu 11.10+ since this was the first version to include OpenJDK 1.7, but it might still be missing more information to solve more problems regarding Minecraft. I also did ...


37

This problem is occurring because the Android SDK is compiled for a 32-bit GNU/Linux system, and your Ubuntu system is a 64-bit GNU/Linux system. The solution should be easy (since Ubuntu fully supports running 32-bit programs on a 64-bit OS)--just install the 32-bit versions of the libraries it needs. The simplest and easiest way to do this is to install ...


21

The simplest way is: update-java-alternatives -l - Shows you all the Java versions you have installed. java -showversion - Shows you the java version you are using and help. java -version - Java Version only Normally it would be OpenJDK.


21

To completely remove OpenJDK on Ubuntu 11.10 (this may or may not be sufficient on other versions of Ubuntu), run: sudo apt-get purge openjdk-\* icedtea-\* icedtea6-\* If you want instructions for removing the proprietary Oracle ("Sun") version of Java, then you'll have to specify how you installed it. (If you edit your question to indicate this and leave ...


20

The problem is that the default-jre package depends on OpenJDK 6 and most other packages have their dependencies defined as default-jre | openjdk-6-jre | sun-java6-jre - so until OpenJDK 7 becomes officially supported and will be used as the default version, or until all Java-dependent packages update their dependencies, you'll have to keep OpenJDK 6 around ...


18

This command should tell you what is currently providing the Java virtual machine (java) and the Java compiler (javac): file /etc/alternatives/java /etc/alternatives/javac This assumes the "alternatives" system is working properly, which might not be the case, depending on how Java has been "messed up" in the past. To check this, run: file `which java ...


17

I had exactly the same problem today. First, a little googling brought me to your issue (didn't assumed to be due to OpenJDK). After a little more research, finally solved this strange behaviour: have a look at this ubuntu-bug. So the quick solution is just to run sudo apt-get --reinstall install tzdata-java (reinstalling Time zone and daylight-saving time ...


17

Installing JDK To install JDK, you can refer to help.ubuntu.com/community/Java. If you want to install openJDK, sudo apt-get install openjdk-7-jdk If you want to install Oracle JDK, you can use PPA from webup8 team. sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java7-installer Installing IntelliJ IDEA ...


16

Sun Java has been disabled via a security update due to it exposing users to known security holes and has been removed from the partner archive. Due to the severity of the security risk, Canonical is immediately releasing a security update for the Sun JDK browser plugin which will disable the plugin on all machines. This will mitigate users' risk from ...


15

Feel free to use this as a reference to tinkering with Java at runtime. Choosing your JRE To choose your JRE, use sudo update-alternatives --config java This will give something like the following output. Selection Path Priority Status ------------------------------------------------------------ 0 ...


15

This thread was the fix for me. Specifically, installing this package: sudo apt-get install lib32z1 lib32z1-dev


14

There are currently two java versions (vendors, if you will) available: Oracle's (Previously Sun) JDK, the closed source java, with commertial support from oracle 'n stuff. OpenJDK, the open source java. Oracle released part of their source and renamed it. In the days of java6, there used to be a big difference between the two of them, OpenJDK running ...


13

Update I found two repository but I do not recommend OpenJDK builds (all archs) ppa:openjdk-r/ppa OpenJDK 8 backport for trusty ppa:jochenkemnade/openjdk-8 Original Message If you realy want to use OpenJDK, you have to compile from source. There is not still any PPA for OpenJDK. It has been requested at ...


12

OpenJDK 8 was released in March 2014. As of the time of this question, there are no OpenJDK 8 packages in the official Ubuntu repositories for any Ubuntu release. They "will be available soon", as the JDK 8 project page says, for some definition of soon. First, the OpenJDK 8 packages will land in the Ubuntu development release. This may happen during the ...


12

For installing Oracle Java 7: sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo mkdir -p /usr/lib/mozilla/plugins #just in case, this will be added to the package in the next version sudo apt-get install oracle-jdk7-installer Are "PPA's" safe to add to my system, and what are some "red flags" to watch out for? ...


11

Great question, I was wondering this myself. I found that you can use the following to remove the openjdk-7-jre on Ubuntu 13.04: sudo apt-get autoremove openjdk-7-jre Press 'y' and then press enter when prompted to confirm this change. This should also clean up all the additional dependency libraries that were installed with it. I also found you can use ...


10

Installing OpenJDK - Recommended The simplest way to install Java on Ubuntu is to use OpenJDK. This will work fine for most people. To install it, click on the small button with the Ubuntu logo on it, as shown in the screenshot below. After opening the Dash Home, you need to type in Terminal. Click on the icon that is circled in the screenshot below. ...


9

You cannot remove OpenJDK 7 because it is not installed. If you are trying to remove OpenJDK 6, try sudo apt-get remove openjdk-6-jdk, or sudo apt-get remove default-jdk. apt-cache search only shows you available packages, not the packages you have installed. For that, try sudo dpkg --list; sudo dpkg --list | grep -i jdk will show you any JDK-related ...


8

Got the solution. As openjdk documentation says I installed openjdk using sudo apt-get install openjdk-7-jre But it's not complete installation. After that I used this command sudo apt-get install openjdk-7-jdk It installs several extra packages. After that netbeans find jdk automatically and normal installation completed smoothly...


8

update: see Ubuntu Security Notice USN-1693-1 It was discovered that OpenJDK 7's security mechanism could be bypassed via Java applets. If a user were tricked into opening a malicious website, a remote attacker could exploit this to perform arbitrary code execution as the user invoking the program. Probably not for the specific exploit being ...


8

Open your terminal with Ctrl+Alt+T and: Now this will install the latest Java version sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java7-installer


8

You may not need to completely remove the OpenJDK to resolve your problem. Install the sun-java6 packages. Then use update-java-alternatives to switch to the Sun java packages. If you do want to completely remove OpenJDK remove the default-jdk and/or default-jre packages. You may need to remove some java packages but most of them should be happy once ...


8

For this, you must have both versions of jdk installed on your system. you can use apt-get to download both. After that try, $ sudo update-alternatives --config java and select the jdk you want to use. Openjdk is sometimes unfavourable, for some of the applications. You should also try for oracle-java or sun-java. The link below is very useful for ...


8

default-jre This is a simple package which depends on openjdk-7-jre (and so is basically equivalent to openjdk-7-jre) and default-jre-headless. It installs the "Standard Java or Java compatible Runtime", which is OpenJDK 7 JRE. This package points to the Java runtime, or Java compatible runtime recommended for the i386 architecture, which is ...



Only top voted, non community-wiki answers of a minimum length are eligible