RPM

Comment 23 for bug 913192

Revision history for this message
In , Pascal Terjan (pterjan42) wrote :

Reading from an old RH advisory from 2008 there are some options that may help:

=====
As well, this updated package adds a new option flag, "--skip-stat". When
used in conjunction with "--update", createrepo skips calling stat(1) on
files to see if they have changed, and assumes that if the file name
matches, then the repodata can be re-used.

This option has shown a significant increase in performance in the Fedora
build system, cutting down the time it takes createrepo to run, from 40
minutes, to approximately 4.
=====

4 minutes is still quite high but more reasonable.

When uploading a package we have to run it 4 times (i586, x86_64, debug i586, debug x86_64) and currently the total of 4 runs of genhdlist2 takes about 3 minutes (and I had started working on making it faster).

Let's test the performance with that options.

On my home machine on core/release i586 (20115 packages):

First generation with genhdlist2 --clean

real 1m52.755s
user 1m36.790s
sys 0m1.950s

Update with genhdlist2 (and no new package)

real 1m0.889s
user 1m36.080s
sys 0m1.540s

First generation with createrepo

real 10m49.949s
user 6m15.240s
sys 0m12.380s

Update with createrepo --update --skip-stat (and no new package)

real 0m56.652s
user 0m49.190s
sys 0m3.470s

So creating from scratch (which does not happen so often, mostly when we have bugs causing signature problems) takes 5 times longer, for the 4 repositories it would be 44 minutes instead of 7 minutes 30 but updating incrementally (which happens at each package upload) is slightly faster.