天天看點

Centos7使用wget修改為阿裡雲鏡像源

1.安裝wget

yum install -y wget
           

2.完事前都做備份

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

3.下載下傳阿裡雲鏡像檔案

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

4.清理緩存

yum clean all
           

5.生成緩存

yum makecache
           

6.更新最新源設定

yum update -y