当yum -y install XXXX 出现如下问题:
2 3 4 5 6 7 8 9 | Loaded plugins:fastestmirror,refresh-packagekit,security Loading mirror speeds from cached hostfile Could notretrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=i386&repo=os error was 14:PYCURL ERROR6-"Couldn't resolve host 'mirrorlist.centos.org'" Error:Cannot findavalid baseurl forrepo:base [root@chenyi yum.repos.d]# vi CentOS-Base.repo [root@chenyi yum.repos.d]# yum install rrdtool-* Loaded plugins:fastestmirror,refresh-packagekit,security Loading mirror speeds from cached hostfile |
原因:没有配置/etc/resolv.conf
1 2 3 | nameserver 8.8.8.8 nameserver 8.8.4.4 search localdomain |