gpt4 book ai didi

java - sha256sum 不匹配错误在 crunchbang wheezy 上安装 Oracle Java 7

转载 作者:太空狗 更新时间:2023-10-29 12:32:05 25 4
gpt4 key购买 nike

我今天大部分时间都在尝试在我的 crunchbang 发行版上安装 java 7。我最初安装了 OpenJDK,但在安装 mumble 服务器时遇到了问题。现在(不知何故)排序了,但现在我没有 java 7 或 OpenJDK。我的 java 版本是:

matt@crunchbang:~$ java -version
java version "1.5.0"
gij (GNU libgcj) version 4.7.2

Copyright (C) 2007 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

尝试安装 java 7 时(sudo apt-get install Oracle-java7-installer)我最终遇到如下错误:

sha256sum mismatch jdk-7u7-linux-x64.tar.gz
Oracle JDK 7 is NOT installed.
dpkg: error processing oracle-java7-installer (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
oracle-java7-installer
E: Sub-process /usr/bin/dpkg returned an error code (1)

我尝试过的事情:

  • 删除 java 和 java 安装程序
  • 清除 java 和 java 安装程序
  • 使用在堆栈溢出中找到的脚本来告诉我哪些已安装的程序依赖于 java,然后卸载它们。 (这显示了 libreoffice 软件包和几个 java 安装程序)
  • 从网站下载 jre 7,解压,复制到“usr/lib/jvm/”并将其符号链接(symbolic link)到 java 5 文件夹
  • 这个 用户 solution

完整的 java 安装日志:

matt@crunchbang:~$ sudo apt-get install oracle-java7-installer
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
fonts-opensymbol fonts-sil-gentium fonts-sil-gentium-basic gcj-4.7-base gcj-4.7-jre gcj-4.7-jre-headless gcj-4.7-jre-lib gcj-jre
gcj-jre-headless libapache-pom-java libcmis-0.2-0 libcommons-beanutils-java libcommons-collections3-java libcommons-compress-java
libcommons-digester-java libcommons-logging-java libcommons-parent-java libdb-java libdb-je-java libdb5.1-java libdb5.1-java-jni
libexttextcat-data libexttextcat0 libgcj-common libgcj13 libgcj13-awt libgraphite2-2.0.0 libhsqldb-java libhyphen0 libicu4j-java
libjaxp1.3-java libjline-java libjtidy-java liblucene2-java libmythes-1.2-0 libneon27-gnutls libnss3-1d libregexp-java libservlet2.5-java
libvisio-0.0-0 libxalan2-java libxerces2-java libxml-commons-external-java libxml-commons-resolver1.1-java libxz-java
ttf-sil-gentium-basic uno-libs3 ure xfonts-mathml
Use 'apt-get autoremove' to remove them.
Suggested packages:
binfmt-support visualvm ttf-baekmuk ttf-unfonts ttf-unfonts-core ttf-kochi-gothic ttf-sazanami-gothic ttf-kochi-mincho
ttf-sazanami-mincho ttf-arphic-uming
The following NEW packages will be installed:
oracle-java7-installer
0 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
Need to get 0 B/16.2 kB of archives.
After this operation, 88.1 kB of additional disk space will be used.
Preconfiguring packages ...
Selecting previously unselected package oracle-java7-installer.
(Reading database ... 94766 files and directories currently installed.)
Unpacking oracle-java7-installer (from .../oracle-java7-installer_7u7-0~crunchbang~4_all.deb) ...
Processing triggers for desktop-file-utils ...
Setting up oracle-java7-installer (7u7-0~crunchbang~4) ...
Removing outdated cached downloads...
Downloading Oracle Java 7...
--2014-05-23 15:35:08-- http://download.oracle.com/otn-pub/java/jdk/7u7-b10/jdk-7u7-linux-x64.tar.gz
Resolving download.oracle.com (download.oracle.com)... 23.73.181.33, 23.73.181.26
Connecting to download.oracle.com (download.oracle.com)|23.73.181.33|:80... connected.
HTTP request sent, awaiting response... 302 Moved Temporarily
Location: https://edelivery.oracle.com/otn-pub/java/jdk/7u7-b10/jdk-7u7-linux-x64.tar.gz [following]
--2014-05-23 15:35:08-- https://edelivery.oracle.com/otn-pub/java/jdk/7u7-b10/jdk-7u7-linux-x64.tar.gz
Resolving edelivery.oracle.com (edelivery.oracle.com)... 23.78.166.140
Connecting to edelivery.oracle.com (edelivery.oracle.com)|23.78.166.140|:443... connected.
HTTP request sent, awaiting response... 302 Moved Temporarily
Location: http://download.oracle.com/errors/download-fail-1505220.html [following]
--2014-05-23 15:35:09-- http://download.oracle.com/errors/download-fail-1505220.html
Connecting to download.oracle.com (download.oracle.com)|23.73.181.33|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5307 (5.2K) [text/html]
Saving to: `jdk-7u7-linux-x64.tar.gz'

0K 100% 3.48M=0.001s

2014-05-23 15:35:09 (3.48 MB/s) - `jdk-7u7-linux-x64.tar.gz' saved [5307/5307]

Download done.
sha256sum mismatch jdk-7u7-linux-x64.tar.gz
Oracle JDK 7 is NOT installed.
dpkg: error processing oracle-java7-installer (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
oracle-java7-installer
E: Sub-process /usr/bin/dpkg returned an error code (1)

最佳答案

我在我的 chromebook 上运行 crunchbang wheezy 并且遇到了完全相同的问题。

这对我来说是固定的:

I had a similar problem and what i found that worked for me was going into /var/lib/dpkg/info and deleting everything that had that name and you may also have to go into /var/cache/apt/archives and do the same thing. I'm fairly new to linux so if this breaks anything i am sorry. i haven't run into any problems yet that this has caused.

警告:

You are deleting the pre and post install scripts. This can very easily mean that the package will not be installed properly, and it won't be removed properly if you choose to uninstall it. It is THE WRONG THING to do.

但是,我找不到任何其他解决方案。诚然,我有点急于解决这个问题,所以我并没有花太多时间寻找替代解决方案。

(解决方案和引用来自:http://www.linuxquestions.org/questions/debian-26/sub-process-usr-bin-dpkg-returned-an-error-code-1-a-171107/)

关于java - sha256sum 不匹配错误在 crunchbang wheezy 上安装 Oracle Java 7,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23837493/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com