首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >CentOS -使用yum时出错

问CentOS -使用yum时出错
EN

Stack Overflow用户
提问于 2018-08-07 05:47:53
回答 1查看 3.5K关注 0票数 0

当我试着使用yum时,我会发现这个错误,

代码语言:javascript
复制
http://iredmail.org/yum/rpms/6/repodata/repomd.xml: [Errno 14] problem making ssl connection
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: iRedMail. Please verify its path and try again

我尝试了下面的操作,但是错误仍然存在。

代码语言:javascript
复制
yum clean all
rm /var/lib/rpm/__db*
rpm --rebuilddb
yum update

请让我知道如何解决这个问题,谢谢你的帮助。

EN

回答 1

Stack Overflow用户

发布于 2018-08-07 06:41:58

在/etc/yum.repos.d中创建repo.disabled

代码语言:javascript
复制
[root@centos ~]# mkdir /etc/yum.repos.d/repo.disabled
[root@centos ~]# ls /etc/yum.repos.d/
centos.repo centos.repo  centos-updates.repo  centos-updates-testing.repo  
repo.disabled

然后将所有这些3回购文件移动到repo.disabled文件夹中:

代码语言:javascript
复制
[root@centos ~]# mv /etc/yum.repos.d/centos.repo/etc/yum.repos.d/repo.disabled
[root@centos ~]# mv /etc/yum.repos.d/centos-updates.repo/etc/yum.repos.d/repo.disabled
[root@centos ~]# mv /etc/yum.repos.d/centos-updates-testing.repo/etc/yum.repos.d/repo.disabled

列出/etc/yum.store.d中更新的文件和文件夹:

代码语言:javascript
复制
[root@centos ~]# ls -l /etc/yum.repos.d/
total 8
-rw-r--r--. 1 root root   92 Aug 18 00:09 centos.repo
 drwxr-xr-x. 2 root root 4096 Aug 18 11:27 repo.disabled

注意:只有文件centos.repo和文件夹应该存在。

现在,您必须运行yum清除所有的缓存,一切都应该工作得很好。

代码语言:javascript
复制
[root@centos ~]# yum clean all
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/51719617

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档