一、确保更换之前确保自己安装wget,若没安装wget直接命令安装
检查是否安装wget
yum list wget

安装wget
yum -y install wget

二、首先备份
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
三、下载阿里云的yum源到/etc/yum.repos.d/
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo

四、清除缓存
yum clean all
本文介绍了如何在Linux系统上安装或确认wget的安装,并详细阐述了如何备份原有设置、下载阿里云yum源、清除缓存、更新YUM以及验证下载源是否切换至阿里云的过程。
最低0.47元/天 解锁文章

5063

被折叠的 条评论
为什么被折叠?



