ICode9

精准搜索请尝试: 精确搜索
首页 > 系统相关> 文章详细

Centos7中yum源的更新

2021-09-24 16:31:32  阅读:152  来源: 互联网

标签:repo Centos repos 更新 Centos7 etc yum repolist


备份

mkdir /etc/yum.repos.d/repo_bak/
mv /etc/yum.repos.d/*.repo /etc/yum.repos.d/repo_bak/

下载新的CentOS-Base.repo

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

清理缓存、创建缓存

yum clean all
yum makecache

查看启用的yum源和所有的yum源

yum repolist enabled
yum repolist all

更新yum

yum -y update

标签:repo,Centos,repos,更新,Centos7,etc,yum,repolist
来源: https://blog.csdn.net/m0_57086381/article/details/120457838

专注分享技术,共同学习,共同进步。侵权联系[admin#icode9.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有