首页 > 解决方案 > 无法安装 java sdk,webupd8team repo 给出 sha256 错误,并且来自 oracle 的 tar.gz 在 Ubuntu 18.04 上给出了损坏的输出

问题描述

当尝试从 linuxupprising/java 或 ppa:webupd8team/java 安装 java 时,我收到这样的错误

    Hash Sum mismatch
   Hashes of expected file:
    - SHA256:973d8ef6268da61e1003963186b8157207c6bc6e48d37d5e11fc2a5885a5b708
    - SHA1:28ede7da1dca520a59f4d7787511742c9b923084 [weak]
    - MD5Sum:7ba8544ff3e98f3c13d07a1803916781 [weak]
    - Filesize:78077648 [weak]
   Hashes of received file:
    - SHA256:ddb59fc787e254508a3cab0eec31bf0139b9510d83591e0f54a605e6a1f5615b
    - SHA1:1d78a279a988822b0c34312b284e73cd02103425 [weak]
    - MD5Sum:f44ade468641a9aea12a59539886c580 [weak]
    - Filesize:78077648 [weak]

我已经尝试从两个存储库的多个版本进行安装。我也尝试过安装 oracle.com,但是在下载的文件上运行 tar -xzf jdk-version.tar.gz 时,无论我从他们的网站下载的 jdk 版本如何,我都会得到这样的输出

$ sudo tar -xzf jdk-8u181-linux-x64.tar.gz 
tar: Skipping to next header
tar: Archive contains ‘*\264\0\005*\264\0\a’ where numeric mode_t value expected
tar: Archive contains ‘I\003\0\001\0\032\0\030\0\001\0\023’ where numeric time_t value expected
tar: Archive contains ‘\207o\257\0\0\0\002’ where numeric uid_t value expected
tar: Archive contains ‘\024\0\0\0\006\0\001’ where numeric gid_t value expected
tar: *Y�: implausibly old time stamp 1969-12-31 18:59:59
tar: Skipping to next header
tar: Exiting with failure status due to previous errors

它还会生成一个名为 *Y�(无效编码)的空文件

在这一点上我非常迷茫,只想让 jdk 工作。我觉得有些东西被破坏了,但是怎么办?为什么?

标签: javaubuntujava-8failed-installation

解决方案


推荐阅读