MENU

Ubuntu 18 安装java 1.8

August 15, 2019 • Read: 214 • 应用搭建阅读设置

java -version

如果Java的当前未安装,您将看到以下输出:

Command 'java' not found, but can be installed with:

apt install default-jre
apt install openjdk-11-jre-headless
apt install openjdk-8-jre-headless
apt install openjdk-9-jre-headless

安装openjdk

  1. 更新软件包列表:

    sudo apt-get update

  2. 安装openjdk-8-jdk:

    sudo apt-get install openjdk-8-jdk

  3. 查看java版本,看看是否安装成功:

    java -version

兼总条贯 知至知终

无标签