Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stoc

来源:互联网 发布:21天精通javascript 编辑:程序博客网 时间:2024/05/08 07:52
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=7&arch=x86_64&repo=os&infra=stock error was
14: curl#6 - "Could not resolve host: mirrorlist.centos.org; 未知的错误"

通过 网上都是说是由于网络问题造成,我这里的问题是有余源不对造成。
首先,yum时会去寻找
-rw-r--r--. 1 root root 1664 12月  9 2015 CentOS-Base.repo
-rw-r--r--. 1 root root 1309 12月  9 2015 CentOS-CR.repo
-rw-r--r--. 1 root root  649 12月  9 2015 CentOS-Debuginfo.repo
-rw-r--r--. 1 root root  290 12月  9 2015 CentOS-fasttrack.repo
-rw-r--r--. 1 root root  630 12月  9 2015 CentOS-Media.repo
-rw-r--r--. 1 root root 1331 12月  9 2015 CentOS-Sources.repo
-rw-r--r--. 1 root root 1952 12月  9 2015 CentOS-Vault.repo

cat后发现源都是找不到的,由于我们都是内网,需要重新配置下自己的repo文件才可以,具体配置与
通过 /etc/redhat-release 可以看到centos 版本
0 0