更換前先備份系統(tǒng)自帶yum源配置文件覆履,以防萬一
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
下載ailiyun的yum源配置文件到/etc/yum.repos.d/
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
生成緩存
yum makecache
更新系統(tǒng)
yum -y update