yum源

yum 是 Fedora RHEL Centos SUSE等linux 发行版的 软件包管理工具
通过 执行 man yum 查看yum的帮助信息 可以知道
yum makecache 是 将服务器上的软件包信息 现在本地缓存,以提高 搜索 安装软件的速度
yum 主要的一下命令如下:
yum search 软件包 搜索软件包
yum install 软件包 安装软件包
yum remove 软件包
yum update 更新系统

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 5
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
CentOS 6
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
CentOS 7
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
3、之后运行yum makecache生成缓存
yum clean all
yum makecache

163yum源地址
http://mirrors.163.com/.help/CentOS5-Base-163.repo
http://mirrors.163.com/.help/CentOS6-Base-163.repo
http://mirrors.163.com/.help/CentOS7-Base-163.repo

本地yum源安装 yum源的优先级
https://blog.csdn.net/kangvcar/article/details/73477730

你可能感兴趣的:(yum源)