如何在Ubuntu 12.04上安装Java?
我有:
> Java(TM)SE运行时环境(版本1.7.0_21-b11)
> Java HotSpot(TM)64位服务器VM(版本23.21-b01,混合模式)
解决方法:
要安装最新版本的Oracle Java(最新发布在Oracle网页中),最简单的方法是使用Java安装程序(如flashplugin-installer所做),如下所述:http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
Oracle JDK7 itself is not hosted in the PPA because that’s not allowed
by the new Java license (which is also the reason why it has been
removed from the official Ubuntu repositories); the package in the PPA
automatically downloads (and installs) Oracle Java JDK 7 from its
official website and installs it on your computer, just like the
flashplugin-installer package does.
然后,你必须只做这个:
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
并输入以检查版本:
java -version
标签:java,updates
来源: https://codeday.me/bug/20190807/1610931.html