[Yum-devel] Speed improvements to sqlite filelists

Menno Smits menno-yum at freshfoo.com
Mon Feb 7 11:28:04 UTC 2005


Gijs Hollestelle wrote:

> Was this is a yum whatprovides /filename? There was a bug in the code
> that loaded file info on demand, I've added a patch to fix it now.

Nope, it was during a normal "yum update". I've checked out the latest 
version from you SVN today and tried again. The problem has gone away so 
hopefully its something you've fixed.

> Note that yum whatprovides filename is extremely slow at the moment as
> it simply iterates through all files for all packages, instead of
> doing a database lookup for the requested filename.

Yes, searching is a little slow but the imports are noticably faster 
like you said (3x-4x improvement seems about right). The import still 
takes a while though...

I have an idea of using a hybrid approach where most data is kept in 
sqlite but stuff like the filelist data is cached to a simple (but 
structured) text file. This might help minimise the sqlite data import 
cost for the filelist data at the price of slower searching. If I find 
some time I will experiment with this to see how it pans out.

Menno







More information about the Yum-devel mailing list