updates is listed more than once in the configuration 的解决

来源:互联网 发布:cpu评测软件 编辑:程序博客网 时间:2024/06/01 23:04

觉得记性渐渐变差了,决定把遇到的问题记录下来。

最近更新的时候,update后都会先出现

Repository updates is listed more than once in the configurationRepository updates-debuginfo is listed more than once in the configurationRepository updates-source is listed more than once in the configurationRepository fedora is listed more than once in the configurationRepository fedora-debuginfo is listed more than once in the configurationRepository fedora-source is listed more than once in the configurationRepository fzug-free is listed more than once in the configurationRepository fzug-free-source is listed more than once in the configurationRepository fzug-nonfree is listed more than once in the configurationRepository fzug-nonfree-source is listed more than once in the configuration

大概是在一次中断升级之后出现。根据系统自己的建议,使用了

# dnf clean all

可以成功清除缓存,但是以上提示继续存在。

在网上搜寻后参考以下两篇文章解决了问题:

解决 YUM Repository updates is listed more than once in the configuration 的问题

记一次Centos下yum故障的解决过程与方法

过程如下:

# ls -l /etc/yum.repos.d/

看到

-rw-r--r--. 1 root root  649 12月  5 2013 cmplayer-repo.repo-rw-r--r--. 1 root root  689 8月  13 18:44 fedora-cisco-openh264.repo-rw-r--r--. 1 root root 1253 8月  13 18:44 fedora.repo-rw-r--r--. 1 root root 1270 8月  13 18:44 fedora-updates.repo-rw-r--r--. 1 root root 1328 8月  13 18:44 fedora-updates-testing.repo-rw-r--r--. 1 root root 1113 8月  22 11:23 fedora-updates-ustc.repo-rw-r--r--. 1 root root 1157 8月  22 11:23 fedora-ustc.repo-rw-r--r--. 1 root root 1241 8月  24 14:07 rpmfusion-free-rawhide.repo-rw-r--r--. 1 root root 1172 8月  24 14:07 rpmfusion-free.repo-rw-r--r--. 1 root root 1170 8月  24 14:07 rpmfusion-free-updates.repo-rw-r--r--. 1 root root 1230 8月  24 14:07 rpmfusion-free-updates-testing.repo

参考开头的提示,删除了以下源

# rm -rf /etc/yum.repos.d/fzug-free.repo# rm -rf /etc/yum.repos.d/fzug-nonfree.repo# rm -rf /etc/yum.repos.d/FZUG.repo# rm -rf /etc/yum.repos.d/fedora-updates.repo# rm -rf /etc/yum.repos.d/fedora.repo

于是不会出现那一把提示了。

另外参考这个百度知道,出现这种问题的原因是源被提供方删除了。好吧fzug的源是前几天才添加进去的,然而一添加就提示没有用,囧。

centos更新为163的yum源出错


最后,删除文件之前应该做好备份。

0 0