Tente isto:
sudo rm /var/cache/oracle-jdk8-installer/jdk-8u151-linux-x64.tar.gz
Quando eu executo este comando:
sudo apt-get install oracle-java8-installer
então o erro ocorre:
Download done.
Removing outdated cached downloads...
sha256sum mismatch jdk-8u151-linux-x64.tar.gz
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)
Tente isto:
sudo rm /var/cache/oracle-jdk8-installer/jdk-8u151-linux-x64.tar.gz