centos7配置镜像源(阿里)

centos7配置镜像源(阿里)

作者:蓝眼泪

配置centos镜像源整理

1、先将原文件备份

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

2、下载阿里源

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

https://developer.aliyun.com/mirror/centos?spm=a2c6h.13651102.0.0.778c1b11sneLjN

在这里插入图片描述

3、建立cache

yum clean all
yum makecache

4、更新源包

yum -y update

更新epel源,就会有特定的软件。
命令:

yum install epel-release

在这里插入图片描述

在这里插入图片描述

猜你喜欢

转载自blog.csdn.net/qq_31086997/article/details/113862386