HowTo: Upgrade java on Ubuntu 14.04 LTS?
I recently installed Ubuntu 14.04 on my computer and now my Java Version is not updated. I have Java so I dont need to install - just update the current version.
Can someone please tell me the command I have to use to get Version 7 Update 65?
I have tried: apt-get update
and apt-get upgrade
.
Use ppa :
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
if you want java8 :
sudo apt-get install oracle-java8-installer
If you ABSOLUTELY need to have the latest update of java you must manualy install from official source, follow this tuto : http://www.cyberciti.biz/faq/howto-installing-oracle-java7-on-ubuntu-linux/
But I advise you to wait as ppa update
The newest OpenJDK Java packaged for trusty (14.04) right now is 7u55. You can check your Java version with java -version
from the command line in Terminal.
If you want a newer one your best options will be to:
wait for an update from Ubuntu, OR
-
install the Oracle distribution of Java which currently is at 7u65:
sudo add-apt-repository ppa:webupd8team/java sudo apt-get update sudo apt-get install oracle-java7-installer
Found something useful here..
Installing Java with apt-get is easy. First, update the package index:
sudo apt-get update
Check if Java is not already installed:
java -version
Then install java jre/jdk :
sudo apt-get install default-jre
sudo apt-get install default-jdk
For details please go to : https://www.digitalocean.com/community/tutorials/how-to-install-java-on-ubuntu-with-apt-get
Updated for Ubuntu 18.04
Use ppa :
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer
For more infos see: http://www.webupd8.org/2014/03/how-to-install-oracle-java-8-in-debian.html
if you want java9: (Now some Programs like JabRef still need Java8)
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java9-installer
On http://www.webupd8.org/2015/02/install-oracle-java-9-in-ubuntu-linux.html you can see a detailed explanation how to install Java9, and how to change it to default.
if you want Java 10:
sudo add-apt-repository ppa:linuxuprising/java
sudo apt update
sudo apt install oracle-java10-installer
For more infos see: https://www.linuxuprising.com/2018/04/install-oracle-java-10-in-ubuntu-or.html
if you want Java 11:
sudo apt install openjdk-11-jre-headless
sudo apt install openjdk-11-jdk
If you need the latest update you can download it from
- Java 8: https://java.com/de/download/
- Java 9: http://www.oracle.com/technetwork/java/javase/downloads/jdk9-downloads-3848520.html
- Java10: http://www.oracle.com/technetwork/java/javase/downloads/jdk10-downloads-4416644.html
If you have problems to install the latest updates see: https://www.cyberciti.biz/faq/howto-installing-oracle-java7-on-ubuntu-linux/
This question uses content from
- https://askubuntu.com/a/508554/676490 (by @Nymeria)