【问题标题】:Not able to install Java-7 on Debian machine无法在 Debian 机器上安装 Java-7
【发布时间】:2014-08-04 10:30:44
【问题描述】:

我无法在Google Cloud Engine 上安装Java-7。最初我添加了一个ppa 存储库:

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update

知道了:

Hit http://ftp.debian.org wheezy-backports/non-free Translation-en/DiffIndex
Err http://ppa.launchpad.net wheezy/main Sources
404  Not Found
Err http://ppa.launchpad.net wheezy/main amd64 Packages
404  Not Found
Ign http://ppa.launchpad.net wheezy/main Translation-en
Fetched 473 B in 2s (236 B/s)
W: GPG error: http://www.duinsoft.nl debs Release: The following signatures couldn't be    
verified because the public key is not available: NO_PUBKEY E18CE6625CB26B26
W: Failed to fetch 
http://ppa.launchpad.net/webupd8team/java/ubuntu/dists/wheezy/main/source/Sources  404    
Not Found
W: Failed to fetch   
http://ppa.launchpad.net/webupd8team/java/ubuntu/dists/wheezy/main/binary-amd64/Packages    
404  Not Found
 E: Some index files failed to download. They have been ignored, or old ones used 
 instead.

确定为什么apt-get update 不起作用。我删除了/etc/apt/sources.list.d/ webupd8team-java-wheezy.list,然后运行apt-get update。一切正常!

现在,有没有其他方法可以使用CLI 在远程机器上安装java-7。我用谷歌搜索但没有找到任何相关信息(手动安装 java-7 除外)。

【问题讨论】:

    标签: java ubuntu debian java-7


    【解决方案1】:

    如果您没有使用 Java 7 的特定要求,您可以在您的 Debian 版本中安装带有 webupd8 repository 的 Java 8。不过,这些步骤与您在 Java 7 版本中遵循的步骤完全不同。

    您可能知道,安装 JDK 8 并不意味着您的应用程序需要符合 JRE 8:您可以随时在 Eclipse(或您的 IDE)中设置合规级别。

    【讨论】:

    猜你喜欢
    • 2017-07-19
    • 2018-03-22
    • 2015-12-09
    • 1970-01-01
    • 2018-03-29
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-08-25
    相关资源
    最近更新 更多