剛安裝完的centos 6.2系統發明yum客棧更新不了。提示報錯信息:
[[email protected] ~]# yum update
Loaded plugins: aliases, changelog, downloadonly, fastestmirror, kabi, presto, security, tmprepo, verify, versionlock
Loading support for CentOS kernel ABI
Determining fastest mirrors
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os error was
14: PYCURL ERROR 6 - "Couldn't resolve host 'mirrorlist.centos.org'"
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=extras error was
14: PYCURL ERROR 6 - "Couldn't resolve host 'mirrorlist.centos.org'"
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=updates error was
14: PYCURL ERROR 6 - "Couldn't resolve host 'mirrorlist.centos.org'"
http://mirrors.163.com/centos/6.2/os/x86_64/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - "Couldn't resolve host 'mirrors.163.com'"
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again
[[email protected] ~]# service iptables stop
[[email protected] ~]# nslookup mirrorlist.centos.org
;; connection timed out; no servers could be reached
到這里發明問題了,臺灣主機 臺灣伺服器,我的域名理會不了,yum的設置文件里指向的域名就識別不了了。從頭配置下dns指向。
[[email protected] ~]# vim /etc/resolv.conf
# Generated by NetworkManager
search 38forsbm
nameserver 8.8.8.8
[[email protected] ~]# yum update –y --更新可以利用。