LINUX下YUM源配置

  • A+
所属分类:运维教程

#cd /etc/yum.repos.d/

#rm -rf *

#wget https://birdteam.net/wp-content/uploads/2014/04/CentOS-Base.repo_.tar.gz

#tar xvf CentOS-Base.repo_.tar.gz

#yum clean all

#yum check-update

CentOS-Base.repo的内容如下:

[base]

name=CentOS-5 - Base

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

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#released updates

[update]

name=CentOS-5 - Updates

baseurl=http://centos.ustc.edu.cn/centos/5/updates/$basearch/

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#packages used/produced in the build but not released

[addons]

name=CentOS-5 - Addons

baseurl=http://centos.ustc.edu.cn/centos/5/addons/$basearch/

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#additional packages that may be useful

[extras]

name=CentOS-5 - Extras

baseurl=http://centos.ustc.edu.cn/centos/5/extras/$basearch/

gpgcheck=1

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#additional packages that extend functionality of existing packages

[centosplus]

name=CentOS-5 - Plus

baseurl=http://centos.ustc.edu.cn/centos/5/centosplus/$basearch/

gpgcheck=1

enabled=0

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#contrib - packages by Centos Users

[contrib]

name=CentOS-5 - Contrib

baseurl=http://centos.ustc.edu.cn/centos/5/contrib/$basearch/

gpgcheck=1

enabled=0

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

#packages in testing

[testing]

name=CentOS-5 - Testing

baseurl=http://centos.ustc.edu.cn/centos/5/testing/$basearch/

gpgcheck=1

enabled=0

gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-5

yum update后效果:

LINUX下YUM源配置

  • 我的微博
  • 这是微博的扫一扫
  • weinxin
  • 微信公众
  • 微信公众号扫一扫
  • weinxin

发表评论

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

目前评论:77   其中:访客  73   博主  4

    • avatar testzhang 4

      签到成功!签到时间:今日的上午11:40:07,每日打卡,生活更精彩哦!