How To Install Java on Ubuntu with Apt-Get

作者:Rui 发布时间:September 17, 2015 分类:JAVA,CLOUD 浏览:527

Installing Oracle JDK

The Oracle JDK is the official JDK; however, it is no longer provided by Oracle as a default installation for Ubuntu.

You can still install it using apt-get. To install any version, first execute the following commands:

sudo apt-get install python-software-properties
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update

Then, depending on the version you want to install, execute one of the following commands:

Oracle JDK 6

This is an old version but still in use.

sudo apt-get install oracle-java6-installer

Oracle JDK 7

This is the latest stable version.

sudo apt-get install oracle-java7-installer

Oracle JDK 8

This is a developer preview, the general release is scheduled for March 2014. This external article about Java 8 may help you to understand what it's all about.

sudo apt-get install oracle-java8-installer

标签: linux, ubuntu

添加新评论 »