yum 报错:centos yum (28, 'Connection time-out') Trying other mirror.

在本地虚拟机中,使用Yum安装软件时遇到'Connection time-out'错误,即使网络和镜像源正常。问题可能出在DNS配置上,而非repo源。建议将虚拟机的DNS1设置为网关地址,DNS2设置为公共DNS,例如223.5.5.5。完成DNS设置后,再更换Yum源,如切换到阿里云CentOS源,通过备份、替换CentOS-Base.repo文件并运行'yum makecache'生成缓存来解决此问题。
摘要由CSDN通过智能技术生成

问题:

  在本地的虚拟机使用yum安装软件时,经常出现 centos yum (28, 'Connection time-out') Trying other mirror. 或下面的那样情况imeout on http://mirrors.aliyun.com/centos/6/os/x86_64/repodata/repomd.xml: (28, 'Connection time-out') Trying other mirror. 

在centOs上安装软件时。提示超时,或链接不上的信息:

http://mirrors.aliyun.com/centos/6/os/x86_64/repodata/repomd.xml: [Errno 12] Timeout on http://mirrors.aliyun.com/centos/6/os/x86_64/repodata/repomd.xml: (28, 'Connection time-out')
Trying other mirror.
http://mirrors.aliyuncs.com/centos/6/os/x86_64/repodata/repomd.xml: [Errno 12] Timeout on http://mirrors.aliyuncs.com/centos/6/os/x86_64/repodata/repomd.xml: (28, 'Connection time-out')
Trying other mirror.
http://mirrors.cloud.aliyuncs.com/centos/6/os/x86_64/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - "Couldn't resolve host 'mirrors.cloud.aliyuncs.com'"
Trying other mirror.
http://mirrors.aliyun.com/epel/6/x8
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值