Ubuntu 18.04 install JDK8.201
Posted Alex Blog
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Ubuntu 18.04 install JDK8.201相关的知识,希望对你有一定的参考价值。
- sudo add-apt-repository ppa:webupd8team/java
- Press Enter to continue.
- sudo apt update
- sudo apt install oracle-java8-installer
Issues:
- subprocess installed post-installation script returned error exit status 1
Solutions:
- cd /var/lib/dpkg/info
- sudo sed -i \'s|J_DIR=jdk1.8.0_191|J_DIR=jdk1.8.0_201|\' oracle-java8-installer.*
- sudo sed -i \'s|PARTNER_URL=http://download.oracle.com/otn-pub/java/jdk/8u191-b12/2787e4a523244c269598db4e85c51e0c/|PARTNER_URL=https://download.oracle.com/otn-pub/java/jdk/8u201-b09/42970487e3af4f5aa5bca3f542482c60/|\' oracle-java8-installer.*
- sudo sed -i \'s|SHA256SUM_TGZ="640333e749f24428b78c2b10422f7174f8fbd0b8acde27526c195024fad8b6b6"|SHA256SUM_TGZ="12c745fbb8735bf450b8c6ba6f649bebe19915f05742975e443bdc8566170352"|\' oracle-java8-installer.*
- sudo sed -i \'s|J_DIR=jdk1.8.0_191|J_DIR=jdk1.8.0_201|\' oracle-java8-installer.*
- Than reinstall
- sudo apt install oracle-java8-installer
- sudo apt install oracle-java8-set-default
- java –version
Reference:
以上是关于Ubuntu 18.04 install JDK8.201的主要内容,如果未能解决你的问题,请参考以下文章
Installing Ubuntu 18.04 by USB flash drive