1. 程式人生 > >配置 Redhat6 yum 更新源

配置 Redhat6 yum 更新源

  • 更新 repo 檔案(目錄 /etc/yum.repos.d/ 下原來的檔案都是可以刪除的)
    1. vim /etc/yum.repos.d/rhel-debuginfo.repo
    2. 寫入如下內容:
      1. [base]
        name=CentOS-$releasever - Base
        baseurl=http://mirrors.163.com/centos/6/os/$basearch/
        gpgcheck=1
        gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6
        
        #released updates
        [updates]
        name=CentOS-$releasever - Updates
        baseurl=http://mirrors.163.com/centos/6/updates/$basearch/
        gpgcheck=1
        gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6
        
        #packages used/produced in the build but not released
        #[addons]
        #name=CentOS-$releasever - Addons
        #baseurl=http://mirrors.163.com/centos/$releasever/addons/$basearch/
        #gpgcheck=1
        #gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6
        #additional packages that may be useful
        [extras]
        name=CentOS-$releasever - Extras
        baseurl=http://mirrors.163.com/centos/6/extras/$basearch/
        gpgcheck=1
        gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6
        #additional packages that extend functionality of existing packages
        [centosplus]
        name=CentOS-$releasever - Plus
        baseurl=http://mirrors.163.com/centos/6/centosplus/$basearch/
        gpgcheck=1
        enabled=0