- 前言
- 一、环境信息
- 二、更换阿里云镜像源
- 三、安装EPEL 阿里云源
- 总结
前言
更换国内yum源
一、环境信息
| IP地址 | HostName |
|---|---|
| 192.168.235.31 | node1 |
| 192.168.235.32 | node2 |
| 192.168.235.33 | node3 |
| 192.168.235.34 | node4 |
1、备份 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup 2、下载新的CentOS-Base.repo 到/etc/yum.repos.d/ CentOS 7 wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo 或者 curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo 3、之后运行 yum clean all,yum makecache 生成缓存三、安装EPEL 阿里云源
目前可以直接通过执行命令: yum install epel-release -y 直接进行安装,如果此命令无法安装可以尝试以下方法
1、下载新repo 到/etc/yum.repos.d/ epel(RHEL 7) wget -O /etc/yum.repos.d/epel.repo http://mirrors.aliyun.com/repo/epel-7.repo
总结



