配置yum源的步骤(阿里源)
时间:2022-10-13 00:20 作者:Anglei 分类: Linux
配置yum源的步骤
1.可以移除默认的yum仓库,也就是删除 /etc/yum.repos.d/底下所有的.repo文件(踢出国外的yum源)
2.配置yum源,找到阿里云的官方镜像源地址 https://opsx.alibaba.com/mirror
3.下载centos7的yum源
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
4.清空旧的yum缓存
yum clean all
5.生成新的yum仓库缓存(这个缓存来自于阿里云的yum仓库,便于加速软件下载)
yum makecache
6.配置一个第三方的 额外仓库源 (epel源),这个源的作用是,如果阿里云源找不到这个软件,就在这里找
wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo
本文完结,相关标签: yum
推荐阅读:
![]() 路过(0) |
![]() 雷人(0) |
![]() 握手(0) |
![]() 鲜花(0) |
![]() 鸡蛋(0) |