yum and local cache

Jeff Spaleta jspaleta at gmail.com
Fri Sep 10 21:15:02 UTC 2004


On Fri, 10 Sep 2004 23:10:29 +0300, Alin Osan <al at casa.org.ro> wrote:
> If and only if yum gets an error like the one before, it will download
> again all files, will just ignore the files allready downloaded. I'm
> absolutely sure about this, it happen on two distict machines, both
> with rawide, I even checked with tcdump to see if there is any bits
> flow. Otherwise, yum uses the files in cache, but it does not if you
> get a conflict (like the one that I had, "Error:
> xorg-x11-font-utils conflicts:  xorg-x11-base-fonts<= 6.7.99.903-3").
> Meanwhile, yum is a great tool and you are doing a great job. I'm just
> trying to help.

I just created two very small test packages... that conflict... and I
do not see yum redownloading anything after recieving the conflict
error.
yum install barapp foolib
<snip>
Excluding Packages from Local Test
Resolving Dependencies
barapp-0.1-2.i386.rpm     100% |=========================| 1.7 kB    00:00
foolib-0.2-1.i386.rpm     100% |=========================| 1.6 kB    00:00
Error: barapp conflicts:  foolib= 0.2-1

let me point out to you that what you just saw downloaded were the HEADERS
as found in /var/cache/yum/<reponame>/headers
In my test package case /var/cache/yum/local/headers:
-rw-r--r--  1 root root 1716 Sep 10 16:58 barapp-0.1-2.i386.hdr
-rw-r--r--  1 root root 1600 Sep 10 16:59 foolib-0.2-1.i386.hdr
/var/cache/yum/local/packages:
is empty
No packages are downloaded if a detected conflict causes yum to error out.

Now I go back and just install foolib by itself
yum install foolib
<snip>
Excluding Packages from Local Test
Resolving Dependencies
 
Dependencies Resolved
                [i] foolib.i386 0:0.2-1 - user
Is this ok [y/N]: y
foolib-0.2-1.i386.rpm     100% |=========================| 1.9 kB    00:00
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
foolib 100 % done 1/1
Complete!
That download was the download of the actual package. The headers were
NOT re-downloaded!
after this second attempt to install foolib without the conflicting
barapp package,
I now have a cached package.
/var/cache/yum/local/packages:
-rw-r--r--  1 root root 1987 Sep 10 16:59 foolib-0.2-1.i386.rpm


to recap.....
if yum errors out due to a conflict NO PACKAGES WERE DOWNLOADED.
yum downloads headers from the packages during depresolution.
Packages are only downloaded if depresolution clears successfully.
you are NOT seeing redownloading of anything.
The cache IS working, the header files in the cache ARE being reused.

-jef"happy friday afternoon.... time to go kick a puppy"spaleta





More information about the fedora-devel-list mailing list