阿里源地址:https://developer.aliyun.com/mirror/
https://developer.aliyun.com/mirror/centos?spm=a2c6h.13651102.0.0.3e221b11N4IAnS
shellwget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-8.5.2111.repo
shellcurl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-8.5.2111.repo
shellwget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-6.10.repo
shellcurl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-6.10.repo
shellwget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo
shellcurl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo
shell运行 yum makecache生成缓存
其他 非阿里云ECS用户会出现,Couldn’t resolve host ‘mirrors.cloud.aliyuncs.com’信息,不影响使用。用户也可以自行修改相关配置:
shellsed -i -e '/mirrors.cloud.aliyuncs.com/d' -e '/mirrors.aliyuncs.com/d' /etc/yum.repos.d/CentOS-Base.repo
本文作者:YOUWEI
本文链接:
版权声明:本博客所有文章除特别声明外,均采用 ™ 许可协议。转载请注明出处!