RPM

Comment 1 for bug 643551

Revision history for this message
In , Loïc (loc-redhat-bugs) wrote :

Hi,

This was originally filed as a bug against Yum,
https://devel.linux.duke.edu/bugzilla/show_bug.cgi?id=665.

Mach and Mock both fail bootstrapping a root when /var/lib/rpm does not exist on
the host. This seems to be due to the %_rpmlock_path macro which defaults to
%{_dbpath}/__db.000. When /var/lib/rpm does not exist, Yum fails locking over
this file, but Yum should not try using this file when passed an installroot, it
should try using $installroot/var/lib/rpm (which happens to exist and would be
usable).

Yum's upstream commented that this doesn't seem to be a Yum bug, and that I
should preferably file a bug against Mock. See Yum bug #665 for details.

Some relevants logs for this bug:
Success run:
bee% mock -r fedora-devel-i386-core init
init
clean
prep
This may take a while
ending
done
Finished initializing root

Failing run:
bee% mock -r fedora-devel-i386-core init
init
clean
prep
This may take a while
Could not find useradd in chroot, maybe the install failed?
ending
done

I'll attach the resulting root.log which fails during:
Executing /usr/sbin/mock-helper yum --installroot
/var/lib/mock/fedora-development-i386-core/root install buildsys-build
[...]
Transaction Summary
=============================================================================
Install 98 Package(s)
Update 0 Package(s)
Remove 0 Package(s)

Total download size: 100 M
warning: unzip-5.52-2.2.1: Header V3 DSA signature: NOKEY, key ID 897da07a
warning: rpmdevtools-5.3-1.fc6: Header V3 DSA signature: NOKEY, key ID 1ac70ce6
error: can't create transaction lock on /var/lib/rpm/__db.000

Bye,