Was: Software manager crashes in GUI Now: Yum Issue

Phil Meyer pmeyer at themeyerfarm.com
Fri Jul 7 17:45:16 UTC 2006


Jack Gates wrote:
> When I run any yum command other than yum list installed, I get this error:
>
> Searching Packages:
> Setting up repositories
> core                                                                 [1/5]
> updates-released                                                     [2/5]
> extras                                                               [3/5]
> updates                                                              [4/5]
> base                                                                 [5/5]
> Reading repository metadata in from local files
> Error: Caching enabled and local 
> cache: //var/cache/yum/updates-released/primary.xml.gz does not match 
> checksum
>
> I have no idea how to fix this.  Can some one help out?
>   
This occurs when the yum repository you last visited has a different 
checksum for the file.  Happens quite often if you maintain a local 
repository and then hit an outside one.

What is supposed to happen is that if the file is at all different it 
should load it again.  But to make caching at all efficient, there is a 
window of time where yum will make assumptions based upon the last run, 
and sometimes those assumptions can be wrong.  Especially in dealing 
with repositories that change as frequently as Fedora repositories do.

Simple to fix:

sudo yum clean all

Now, try that yum install again.

If you wish to avoid the problem as much as possible in the future, it 
requires that you manually edit the /etc/yum.repos.d/* files and put the 
mirrors you like first on the list.  There is no way that anyone can 
predict which repositories would work best for you, so you have to dig 
for yourself.

It is valid to add a baseurl line before the mirrorlist line in a repo file.

Example ONLY:

[extras]
name=Fedora Extras $releasever - $basearch
baseurl=http://mirror.hiwaay.net/redhat/fedora/linux/extras/$releasever/$basearch/
mirrorlist=http://fedora.redhat.com/download/mirrors/fedora-extras-$releasever
failovermethod=priority
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-extras
gpgcheck=1

try:
 wget -O /tmp/mirr http://fedora.redhat.com/download/mirrors/fedora-extras-5
and look at /tmp/mirr for a list to choose from.  This list changes 
frequently.

Do this for each repository.

Another good way is to do a large yum update and during the downloads, 
hit ^C to cycle through the mirrors until you get a great one.  Then in 
another window do: tethereal
and watch a moment to see where you are currently getting it from, and 
use that one in your updates repo file.

Hope this helps.




More information about the users mailing list