[Rpm-metadata] yum stops talking to repo

Seth Vidal skvidal at fedoraproject.org
Thu Jul 2 15:34:09 UTC 2009



On Wed, 1 Jul 2009, Mike Power wrote:

> I have a rpm repository running on an apache server created by the commend createrepo:
>         cd $YUM_REPO;
>         createrepo -d -v -c $YUM_CACHE -C --update .      
> 
> I added the repository to yum via a .repo file:
>       [nexus]
>       name=Nexus Repository of maven artifacts
>       baseurl=http://yum.mpower.intuit.com/
>       failovermethod=priority
>       gpgcheck=0
>       enabled=1
> 
> When I do a sudo yum clean all; sudo yum update then yum talks to my repo:
>       Loaded plugins: fastestmirror
>       Determining fastest mirrors
>       * jpackage-rhel: jpackage.netmindz.net
>       * base: mirrors.kernel.org
>       * updates: mirrors.cmich.edu
>       * addons: centos.g5selfstorage.com
>       * extras: mirrors.usc.edu
>       nexus                                                    | 1.9 kB     00:00    
>       primary.sqlite.bz2                                       |  31 kB     00:00
> 
> I also see hits in my apache access log:
>       192.168.122.239 - - [01/Jul/2009:20:17:47 -0700] "GET /repodata/repomd.xml HTTP/1.1" 200 1953 "-"
>       "urlgrabber/3.1.0 yum/3.2.19"
>       192.168.122.239 - - [01/Jul/2009:20:17:47 -0700] "GET /repodata/primary.sqlite.bz2 HTTP/1.1" 200 31249 "-"
>       "urlgrabber/3.1.0 yum/3.2.19"
> 
> At this point I add a new version of an rpm to the repo.  I run createrepo to update my files. 
> I finally want to run yum update on the client so that it installs the new rpm.  But this time it doesn't bother talking
> to my repo:
>
>       Loaded plugins: fastestmirror
>       Loading mirror speeds from cached hostfile
>       * jpackage-rhel: jpackage.netmindz.net
>       * base: mirrors.kernel.org
>       * updates: mirrors.cmich.edu
>       * addons: centos.g5selfstorage.com
>       * extras: mirrors.usc.edu
>       Setting up Update Process
> 
> When running this on the client I get zero hits on the access log.  yum didn't even bother asking my repo for new stuff.
> 
> What am I missing?
>

yum has a local cache timeout.

check out the variables in yum.conf man page:

   metadata_expire
         Time (in seconds) after which the metadata will expire. So that
         if the current metadata downloaded is less than this many
         seconds old then yum will not update the metadata against
         the repository.  If you find that yum is not downloading
         information on updates as often as you would like lower the value
         of this option. You can also change from the default of using
         seconds to using days, hours or minutes by appending a d, h or m
         respectively.  The default is 1.5 hours, to compliment
         yum-updatesd running once an hour.  It’s also possible to use the
         word "never", meaning that the metadata will never expire. Note
         that when using a metalink file the metalink must always be newer
         than the metadata for the repository, due to the validation, so
         this timeout also applies to the metalink file.

-sv


More information about the Rpm-metadata mailing list