wget: unable to resolve host address ?.ublic-yum.oracle.com?

[root@node2 ~]# uname -a
Linux node2 2.6.32-504.el6.x86_64 #1 SMP Tue Sep 16 01:56:35 EDT 2014 x86_64 x86_64 x86_64 GNU/Linux
[root@node2 ~]# 
[root@node2 ~]# 
[root@node2 ~]# cat /etc/issue
Red Hat Enterprise Linux Server release 6.6 (Santiago)
Kernel \r on an \m

[root@node2 ~]# 
[root@node2 ~]# 
[root@node2 ~]# cd /etc/yum.repos.d
[root@node2 yum.repos.d]# wget http://public-yum.oracle.com/public-yum-ol6.repo
--2021-07-15 07:07:14--  http://public-yum.oracle.com/public-yum-ol6.repo
Resolving public-yum.oracle.com... failed: Temporary failure in name resolution.
wget: unable to resolve host address ?.ublic-yum.oracle.com?
[root@node2 yum.repos.d]# wget http://public-yum.oracle.com/public-yum-ol6.repo
--2021-07-15 07:07:46--  http://public-yum.oracle.com/public-yum-ol6.repo
Resolving public-yum.oracle.com... failed: Temporary failure in name resolution.
wget: unable to resolve host address ?.ublic-yum.oracle.com?
[root@node2 yum.repos.d]# 

试了下,外网可以 上,但是下不了public-yum-ol6.repo,单独网页打开http://public-yum.oracle.com/public-yum-ol6.repo可以看到内容

wget: unable to resolve host address ?.ublic-yum.oracle.com?

这里看应该是找不到主机,那就是域名解析问题

编辑文件,保存

[root@node2 yum.repos.d]# vi /etc/resolv.conf 

# Generated by NetworkManager


# No nameservers found; try putting DNS servers into your
# ifcfg files in /etc/sysconfig/network-scripts like so:
#
# DNS1=xxx.xxx.xxx.xxx
# DNS2=xxx.xxx.xxx.xxx
# DOMAIN=lab.foo.com bar.foo.com


nameserver 8.8.8.8

可以下载了

[root@node2 yum.repos.d]# wget http://public-yum.oracle.com/public-yum-ol6.repo
--2021-07-15 07:10:34--  http://public-yum.oracle.com/public-yum-ol6.repo
Resolving public-yum.oracle.com... 23.42.151.167
Connecting to public-yum.oracle.com|23.42.151.167|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 12045 (12K) [text/plain]
Saving to: ?.ublic-yum-ol6.repo?

100%[=============================================================================================================================================================>] 12,045      --.-K/s   in 0s      

2021-07-15 07:10:34 (112 MB/s) - ?.ublic-yum-ol6.repo?.saved [12045/12045]

[root@node2 yum.repos.d]#

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值