如何在Ubuntu Server上安装Java?

huangapple 未分类评论52阅读模式
英文:

How to install Java on Ubuntu Server?

问题

我需要在Ubuntu Server 18.04上安装Oracle JDK 11。我看过很多教程,但所有教程都指出我需要下载这个软件仓库:

sudo add-apt-repository ppa:linuxuprising/java

但这并没有起作用。我得到了以下内容:

如何在Ubuntu Server上安装Java?

此外,我还需要在同一台Ubuntu机器上安装Open JDK 14,但我找不到可行的指南。

有人对这些问题有任何提示吗?

英文:

I need to install Oracle JDK 11 on Ubuntu Server 18.04. I have seen many tutorials but all of those point that I need to download this repository:

sudo add-apt-repository ppa:linuxuprising/java

But it is not working. This is what I get:

如何在Ubuntu Server上安装Java?

Also, I need to install Open JDK 14 in the same Ubuntu machine, but I'm unable to find working instructions.

Does somebody have any hints on these issues?

答案1

得分: 0

实际上,只需键入"sudo apt-get install openjdk-11-jdk"或"sudo apt-get install openjdk-14-jdk"即可。

这应该有助于您处理所有OpenJDK相关的事项。
https://wiki.ubuntuusers.de/Java/Installation/OpenJDK/

英文:

Actually it should be possible to just type "sudo apt-get install openjdk-11-jdk" or "sudo apt-get install openjdk-14-jdk"

This should Help you with all the OpenJDK stuff
https://wiki.ubuntuusers.de/Java/Installation/OpenJDK/

huangapple
  • 本文由 发表于 2020年4月7日 08:39:33
  • 转载请务必保留本文链接:https://java.coder-hub.com/61071076.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定