安装wget命令
yum -y install wget
备份yum源
切换目录
cd /etc/yum.repos.d
重命名
mv CentOS-Base.repo CentOS-Base.repo.bak
阿里云yum源配置文件
wget -O Centos-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
yum源生成缓存
yum makecache
更新yum源
yum -y install update
yum -y install wget
cd /etc/yum.repos.d
mv CentOS-Base.repo CentOS-Base.repo.bak
wget -O Centos-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
yum makecache
yum -y install update