Createrepo ignoring additional versions of packages

0

I have a repo where I need to be able to serve older versions of a package to clients.

However, when I run createrepo on a given directory with those older versions of a package present, it only builds the filelists.xml with the most recent version.

When I run createrepo, I can see that it's considering all the packages when it spawns the worker.

For example a repo in /var/foo with packages:

foo-bar-0.1-1.noarch.rpm
foo-bar-0.2-1.i386.rpm
foo-bar-0.3-1.i386.rpm
foo-bar-0.4-1.i386.rpm

Running createrepo will show that it's reading all the packages

Worker 0: reading foo-bar-0.1-1.noarch.rpm
Worker 0: reading foo-bar-0.2-1.i386.rpm
Worker 0: reading foo-bar-0.3-1.i386.rpm
Worker 0: reading foo-bar-0.4-1.i386.rpm

But the end result of the filelists.xml only has the latest version of the i386.rpm and the noarch.rpm version.

I have tried passing the list of files I want to the -i option of createrepo, but it continues to dedupe the older versions and only serves up the most recent.

This results in the clients not being able to see the older versions of the package.

Does anyone know how to ensure that all versions of all packages are represented in the filelists.xml so that it will be served up by yum?

I'm on Centos5 using yum-3.2.22-39.el5.centos and createrepo-0.4.11-3.el5

donovan.lampa

Posted 2013-08-30T15:00:58.710

Reputation: 193

Answers

0

I figured out what the issue is here.

I was syncing packages from one box to another and the two boxes were using different versions of createrepo. The box I was syncing packages and repomd from didn't have the older versions of the package in its repo. The Centos6 version md5sums its metadata files while the centos5 version does not. Yum apparently prefers to use the non-md5summed version and thus wasn't able to see all the versions of the packages on the final box.

Stupid mistake on my part. Hopefully nobody else will have this problem and learn from my mistakes.

donovan.lampa

Posted 2013-08-30T15:00:58.710

Reputation: 193