centos7使用国内源
清华大学 CentOS 镜像
1 2 3 4 | sudo sed -e 's|^mirrorlist=|#mirrorlist=|g' \
-e 's|^#baseurl=http://mirror.centos.org|baseurl=https://mirrors.tuna.tsinghua.edu.cn|g' \
-i.bak \
/etc/yum.repos.d/CentOS-*.repo
|
1 2 3 | #更新软件包缓存 sudo yum makecache |