centos:换源

备份本地yum源

mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo_bak

获取阿里yum源配置文件

wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

更新cache

yum makecache

更新package

yum -y update

update vs upgrade(参考man yum)


posted @ 2021-03-25 10:59  rxh1999  阅读(53)  评论(0)    收藏  举报