The same occurs with rpm 4.2.3-21_nonptl on RHEL3. +++ This bug was initially created as a clone of Bug #117997 +++ Description of problem: rpm 4.2 (at least 2004-01-07 cvs snapshot) does not close its database properly with --root option. Seems that all database files except Packages and Name are opened after rpm calls chroot(), but the database is closing by one (AFAIK) function dbenv->close() (called from db_fini()) after rpm leaves "chroot jail". How reproducible: Every time Steps to Reproduce: # mv /var/lib/rpm /var/lib/rpm- # mkdir /tmp/foo # rpm --root=/tmp/foo --initdb # rpm --root=/tmp/foo -i foo.rpm rpmdb: /var/lib/rpm/Filemd5s: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Sha1header: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Sigmd5: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Installtid: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Provideversion: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Requireversion: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Dirnames: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Triggername: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Providename: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Requirename: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Group: unable to flush: No such file or directory rpmdb: /var/lib/rpm/Basenames: unable to flush: No such file or directory error: db4 error(2) from dbenv->close: No such file or directory
Created attachment 121653 [details] Test case shell script Script to attempt to reproduce
Created attachment 121654 [details] Specfile for test case Build then place in same dir as test script and run test.sh Look for messages.
The above test case works fine for me (ie no error) on rpm 4.2.3-24_nonptl. Are people still seeing this with U6? If so can they ammend the test case appropriately so I reproduce here.
Works with U6, thanks.