[root@linux-212 pcre-8.13]# yum install gcc

Loaded plugins: fastestmirror, refresh-packagekit, security

Loading mirror speeds from cached hostfile

* c6-media:

file:///media/CentOS_6.2_Final/repodata/repomd.xml: [Errno 14] Could not open/read file:///media/CentOS_6.2_Final/repodata/repomd.xml

Trying other mirror.

Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again

[root@linux-212 pcre-8.13]# cd /etc/yum.repos.d/

[root@linux-212 yum.repos.d]# ll

总用量 24

-rw-r--r--  1 root root 2126  6月  5 18:22 CentOS-Base.repo

-rw-r--r--. 1 root root 1926  6月  5 14:49 CentOS-Base.repo.bak

-rw-r--r--. 1 root root  637 12月  9 2011 CentOS-Debuginfo.repo

-rw-r--r--  1 root root  637  6月  5 18:23 CentOS-Debuginfo.repo.bak

-rw-r--r--  1 root root  623  6月 20 09:37 CentOS-Media.repo

-rw-r--r--  1 root root  626  6月 20 09:35 CentOS-Media.repo.bak

[root@linux-212 yum.repos.d]#

修改yum地址

[debug]

name=CentOS-6 - Debuginfo

#baseurl=http://debuginfo.centos.org/6/$basearch/

baseurl=http://centos.ustc.edu.cn/centos/5/os/i386/

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-Debug-6

enabled=0