centos7rpm包安装jdk报错解决

由于版权原因,Linux发行版并没有包含官方版的Oracle JDK,必须自己从官网上下载安装。Oracle官网用Cookie限制下载方式,使得眼下只能用浏览器进行下载,使用其他方式可能会导致下载失败。但还是有方法可以在Linux进行下载的,

error: open of href=http://www.oracle.com/us/sitemaps/index.html </tr> <tr valign=middle> <td align=right valign=top><img src=/errors/us/assets/004894.gif height=7 vspace=3></td> <td><a href=http://www.oracle.com/technetwork/index.html>OTN Homepage</a></td> </tr> </table> <br> <div id=footer> <table width=100%  border=0 cellspacing=0 cellpadding=0> <tr> <td width=50% class=legalese align=right valign=top>&nbsp;</td> <td width=50% class=legalese align=left valign=top >&nbsp;</td> </tr> <tr> <td width=50% class=legalese align=left valign=top>&nbsp;</td> <td width=50% class=legalese align=right valign=top><a class=legalese href=http://www.oracle.com/rss/index.html target=_top>RSS <img src=/errors/us/assets/feed-icon-14x14.png width=14 height=14 border=0></A><span class=navlink> | </span> <a class=legalese href=http://www.oracle.com/html/copyright.html target=_top>Legal Notices and Terms for Use</a><span class=navlink> | </span> <a class=legalese href=http://www.oracle.com/html/privacy.html target=_top>Privacy Statement</a><br /> </td> </tr> <tr> <td width=50% class=legalese align=right valign=top>&nbsp;</td> <td width=50% class=legalese align=left valign=top ></td> </tr> </table> </div> </td> <TD WIDTH=10><IMG SRC=/errors/us/assets/spacer.gif BORDER=0 ALT= WIDTH=10></TD> </tr> </table> </body> </html> failed: No such file or directory

我们需要三个参数:–no-check-certificate、–no-cookies、–header,通过man wget命令可以查到。
用于禁止检查证书

wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" Unauthorized Request

rpm -ivh jdk-8u131-linux-x64.rpm 再安装即可

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值