0

I ran the following commands to install java: sudo add-apt-repository ppa:webupd8team/java and sudo apt-get update. After that I ran sudo apt-get install oracle-java8-installer and got an error. Here's the error:

Connecting to download.oracle.com (download.oracle.com)|2.21.176.162|:80... connected.
HTTP request sent, awaiting response... 404 Not Found
2018-04-17 17:13:56 ERROR 404: Not Found.

download failed

Oracle JDK 8 is NOT installed.
dpkg: error processing package oracle-java8-installer (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 oracle-java8-installer
E: Sub-process /usr/bin/dpkg returned an error code (1)

Did I miss a step here? I searched for this error and the only thing I found was a question here in AskUbuntu instructing OP to run sudo apt-get purge oracle-java9-installer (I changed java9 to java8 since I'm trying to install java 8) then ran the command sudo apt-get install oracle-java8-installer again. It did not work.

jaryl
  • 3
  • 3

2 Answers2

0

A new Java version was released: http://www.oracle.com/technetwork/java/javase/downloads/index.html I guess you'll have to wait for the PPA to add the new version and then try again.

Logix
  • 2,230
0

Uninstalling openJDK solved my problem. I uninstalled it and then ran sudo apt-get install oracle-java8-installer again. Now Java 8 is installed.

jaryl
  • 3
  • 3