Description of problem: After upgrading to latest rpm from rawhide (previous version was the previous rpm from rawhide) the rpm does not work anymore. Version-Release number of selected component (if applicable): rpm-4.2-0.68 popt-1.8-0.68 How reproducible: Always Steps to Reproduce: (as root) 1. upgrade to rpm-4.2-0.68 and popt-1.8-0.68 (rawhide from today) 2. rpm -q rpm (any package) -> error message (as normal user you CAN do rpm -q package without error!?) I also tried to remove __db* files, but it did not help. Actual Results: rpmdb: unable to join the environment error: db4 error(11) from dbenv->open: Resource temporarily unavailable error: cannot open Packages index using db3 - Resource temporarily unavailable (11) error: cannot open Packages database in /var/lib/rpm package rpm is not installed Additional info: strace (if it helps anything) ... open("/usr/share/locale/en_US/LC_MESSAGES/rpm.mo", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/share/locale/en/LC_MESSAGES/rpm.mo", O_RDONLY) = -1 ENOENT (No such file or directory) futex(0x4212e028, FUTEX_WAKE, 2147483647, NULL) = 0 stat64("/var/lib/rpm/DB_CONFIG", 0xbfffcea0) = -1 ENOENT (No such file or directory) open("/var/lib/rpm/DB_CONFIG", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory) stat64("/var/lib/rpm/__db.001", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 open("/var/lib/rpm/__db.001", O_RDWR|O_DIRECT|O_LARGEFILE) = 3 fcntl64(3, F_SETFD, FD_CLOEXEC) = 0 fstat64(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 close(3) = 0 select(0, NULL, NULL, NULL, {3, 0}) = 0 (Timeout) stat64("/var/lib/rpm/__db.001", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 open("/var/lib/rpm/__db.001", O_RDWR|O_DIRECT|O_LARGEFILE) = 3 fcntl64(3, F_SETFD, FD_CLOEXEC) = 0 fstat64(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 close(3) = 0 select(0, NULL, NULL, NULL, {6, 0}) = 0 (Timeout) stat64("/var/lib/rpm/__db.001", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 open("/var/lib/rpm/__db.001", O_RDWR|O_DIRECT|O_LARGEFILE) = 3 fcntl64(3, F_SETFD, FD_CLOEXEC) = 0 fstat64(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 close(3) = 0 select(0, NULL, NULL, NULL, {9, 0}) = 0 (Timeout) stat64("/var/lib/rpm/__db.001", {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 open("/var/lib/rpm/__db.001", O_RDWR|O_DIRECT|O_LARGEFILE) = 3 fcntl64(3, F_SETFD, FD_CLOEXEC) = 0 fstat64(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0 close(3) = 0 write(2, "rpmdb: ", 7rpmdb: ) = 7 write(2, "unable to join the environment", 30unable to join the environment) = 30 ...
What kernel and glibc ? You probably want to upgrade to the kernel and glibc from Raw Hide as well. rpm uses/needs futexes from NPTL available in those packages.
glibc-2.3.1-46 kernel-2.4.20-2.30 2.4.20-2.30 #1 Fri Jan 31 08:46:20 EST 2003 i686 athlon i386 GNU/Linux Now I guess those are the latest. And even if they were not, how am I supposed to upgrade them if my rpm is broken? :)
Try rm -f /var/lib/rpm/__db* and repeat. If that hangs, then add to /etc/rpm/macros (note "private") %__dbi_cdb create private cdb mpool mp_mmapsize=16Mb mp_size=1Mb
This did not help: rm -f /var/lib/rpm/__db* Also there is no file /etc/rpm/macros I create the file /etc/rpm/macros and added the line you asked and now everything works. Thanks. :)
OK. You should upgrade to latest glibc/kernel from Raw Hide, and then delete /etc/rpm/macros.