收集于網絡
剛裝了FC6,由于在教育網,無法使用yum默認的國外更新源,因此需要將其設置為國內鏡像站點。在網上找了一圈,發(fā)現清華的 ftp://ftp3.tsinghua.edu.cn這個更新源不錯。參考網上的一些方法,設置yum更新源步驟如下:
1. 將/etc/yum.repos.d/下的已有更新源(repo文件)的enable改為0。為了方便起見,可以直接 mv /etc/yum.repos.d /etc/yum.repos.d.bak重命名,這樣就讓系統找不到原有的repo文件了。
2. 修改/etc/yum.conf文件,添加如下內容:
# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
[extras]
name=Fedora Extras $releasever - $basearch
baseurl=ftp://ftp3.tsinghua.edu.cn/mirror/download.fedora.redhat.com/pub/fedora/linux/extras/6/i386
enabled=1
[updates]
name=Fedora Core $releasever - $basearch - Updates
baseurl=ftp://ftp3.tsinghua.edu.cn/mirror/download.fedora.redhat.com/pub/fedora/linux/core/updates/6/i386
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora
[core]
name=Fedora Core $releasever - $basearch
baseurl=ftp://ftp3.tsinghua.edu.cn/mirror/download.fedora.redhat.com/pub/fedora/linux/core/6/i386/os
enable=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora file:///etc/pki/rpm-gpg/RPM-GPG-KEY
3. 經過上述步驟后,就可以使用速度較快的國內鏡像站點作為yum更新源了。
后記:在使用yum進行install時,經常會出現下面的錯誤
warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID 1ac70ce6
導致安裝不能進行。解決方法如下:
rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY*
附:上述步驟的參考文獻
http://cocooker.gro.clinux.org/system-source.html 1.3. 軟件源的設置
http://www.neupioneer.com/city/blog/more.asp?name=codered&id=33152 南嶺梅香-我的FC6安裝配置日志
http://www.linuxsir.org/bbs/showthread.php?t=209957 yum安裝時下載完畢,但卻出現warning!Help!!!!
posted on 2007-04-09 19:30
流浪汗 閱讀(2092)
評論(0) 編輯 收藏 所屬分類:
Linux