Bug 950301

Summary: weird comps handling
Product: [Fedora] Fedora EPEL Reporter: Dennis Gilmore <dennis>
Component: createrepo_cAssignee: Tomas Mlcoch <tmlcoch>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: el6CC: jzeleny, tmlcoch
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: createrepo_c-0.4.0-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-24 17:59:57 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Dennis Gilmore 2013-04-10 03:36:09 UTC
Description of problem:

the output of https://arm.koji.fedoraproject.org/koji/taskinfo?taskID=1696566 shows a lot of comps files. i suspect when updating its including all of the old versions of comps rather than just the one we have now.

Comment 1 Tomas Mlcoch 2013-04-11 07:55:30 UTC
Hi Dennis,
I'm not quite sure if it's a bug or not. This behavior is based on original createrepo and at least my current createrepo-0.9.9-13.fc19 behave in this way. I could change it, that is not a problem.
But I wonder if your version of original createrepo behave differently?

I am looking on a createrepo/createrepo/__init__.py doFinalMove method. This method do (simplified):

1) Move current repodata/ -> old_repodata/
2) Move created .repodata/ -> repodata/
3) Remove primary, filelists, other, repomd, groupfile file from old_repodata/ only if a file with the same name exists in repodata/
4) Build lists: primary, primary_db, filelists, filelists_db, other, other_db which contains corresponding files from old_repodata/, sort them by mtime and except first N (set by --retain-old-md) put them into the old_to_remove list.
5) Iterate over files in old_repodata/. If the current filename is primary.sqlite, filelists.sqlite, other.sqlite or is present in old_to_remove or filename with the same name exists in repodata/ then remove the file and continue. Else if the file with this name doesn't exists in repodata/ move it there.
6) Cleanup (Remove old_repodata etc.)

So if the comps file is changed then its name is changed as well (checksum in the name of file is changed) -> createrepo keep the file during update.

Comment 2 Fedora Update System 2014-05-06 13:43:53 UTC
createrepo_c-0.4.0-1.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/createrepo_c-0.4.0-1.el6

Comment 3 Fedora Update System 2014-05-06 17:32:31 UTC
Package createrepo_c-0.4.0-1.el6:
* should fix your issue,
* was pushed to the Fedora EPEL 6 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=epel-testing createrepo_c-0.4.0-1.el6'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-EPEL-2014-1342/createrepo_c-0.4.0-1.el6
then log in and leave karma (feedback).

Comment 4 Fedora Update System 2014-05-24 17:59:57 UTC
createrepo_c-0.4.0-1.el6 has been pushed to the Fedora EPEL 6 stable repository.  If problems still persist, please make note of it in this bug report.