[CentOS] FYI: solution Re: mock %post(pam) failure

Alan Evans

alan.evans at secure-24.com
Tue Jun 16 01:23:22 UTC 2009


Farkas' solution is exactly right.  I have been banging my head against
this problem for a while now and it wasn't until I finally paced myself
and read carefully through the entire thread that I found this solution.

Here is the procedure spelled out a bit more precisely.
 
Get the CentOS 5.2 rpms of popt, rpm, rpm-libs, rpm-python and
rpm-build.  Obviously you can use most any mirror and if you are using
i386 you should replace x86_64 with i386.  I prefer to use RIT since its
my Alma Mater and they seem to have good bandwidth and keep older
versions.

# wget
http://mirrors.rit.edu/centos/5.2/os/x86_64/CentOS/popt-1.10.2-48.el5.x8
6_64.rpm
# wget
http://mirrors.rit.edu/centos/5.2/os/x86_64/CentOS/rpm-4.4.2-48.el5.x86_
64.rpm
# wget
http://mirrors.rit.edu/centos/5.2/os/x86_64/CentOS/rpm-build-4.4.2-48.el
5.x86_64.rpm
# wget
http://mirrors.rit.edu/centos/5.2/os/x86_64/CentOS/rpm-libs-4.4.2-48.el5
.i386.rpm
# wget
http://mirrors.rit.edu/centos/5.2/os/x86_64/CentOS/rpm-python-4.4.2-48.e
l5.x86_64.rpm

It took some testing but because we are rolling back several packages
RPM handled the dependencies a little weird but here's the rpm command
that does all the magic.

# rpm -Uvh --oldpackage --nodeps popt-1.10.2-48.el5.x86_64.rpm
rpm-4.4.2-48.el5.x86_64.rpm rpm-libs-4.4.2-48.el5.i386.rpm
rpm-python-4.4.2-48.el5.x86_64.rpm

--nodeps is required because rpm complains about needing to fill some
dependencies for 4.4.2-48 but we are in fact trying to install those
very dependencies so we have to tell rpm not to bother.

If you are concerned throw in a --test switch to make sure everything
goes well.  I never like using rpm to roll back rpm, just seems
dangerous, like crossing the streams.

After rolling back to the CentOS 5.2 versions of popt, rpm, rpm-libs and
rpm-python I am able to successfully init the epel-5-i386 mock root.  I
tested several times and made sure to clear the build root and yum
caches in my tests.

Farkas' suggested this might be a bug in rpm or popt which seems to hold
true.  Clearly between point releases something changed that caused rpm
to behave slightly differently when it comes to ordering transactions.
I am comfortable now using the slightly outdated RPMs but I wonder what
will happen in CentOS 5.4/5.5 and so on.

Regards,
-Alan

KEYWORDS: mock 0.9.14, CentOS 5.3, coreutils 5.97, pam 0.99.6.2



More information about the CentOS mailing list