> On Thursday 03 February 2011 15:18:02 Jeff Johnson wrote:
> > The procedure isn't hard, its essentially this 1 command (snipped from
> > tests/Makefile.am) ...
> >
> > @__DB_DUMP@ olddb/Packages \
> >
> > | sed \
> > |
> > -e 's/^type=hash$$/type=btree/' \
> > -e '/^h_nelem=/d' \
> > -e 's/^ \(..\)\(..\)\(..\)\(..\)$$/ \4\3\2\1/' \
> >
> > | @__DB_LOAD@ newdb/Packages; \
> >
> > [...]
> >
> > That process (with hardening) is being accomplished in Mandriva and IDMS
> > by adding to rpm.spec
> >
> > %posttrans
> > /usr/lib/rpm/dbconvert.sh
>
> The procedure is clear, thanks, I'll try this when it's time for another
> rpm upgrade (i.e. when other current higher priority distribution tasks
> are completed).
On a couple of arm devices with kernel 2.6.28 and 2.6.29 I noticed that there
is maybe a kernel bug which causes rpm 5.2.1 to fail with a kernel oops. The
problem was in beecrypt 4.1.2 and though I was able to fix similar problems
with other libraries, I didn't succeed with beecrypt. So I tested beecrypt
4.2.1 and it works in this environment so now I need to move necessarily to
rpm 5.3.8 because 5.2.1 is not compatible with beecrypt 4.2.1.
I have and upgrade problem which in short is the following:
rpmdb: unrecognized name-value pair: set_create_dir
rpmdb: unrecognized name-value pair: set_create_dir
error: db3open:db3.c:2318: dbenv->open(22): Invalid argument
error: cannot open Packages(0) index: Invalid argument(22)
DB: Berkeley DB 4.7.25: (May 15, 2008)
error: cannot open Packages database in /var/lib/rpm
This happens:
1) when using rpm 5.2.1 to create a chroot environment and installing
packages; after installing the package rpm the next rpm 5.2.1 invocation will
fail. This sounds strange to me because rpm 5.3.8 is just installed but never
executed from the chroot directory, so the database should still be 5.2.1
compatibile but it isn't. Does rpm -r /my/chroot/dir -i mypackage use some
components in the chroot environment which may modify the db?
2) when installing the new rpm where an old db exists. I've tryed the
suggested procedure:
db_dump-47 /var/lib/rpm.old/Packages | sed -e 's/^type=hash$$/type=btree/' -e
'/^h_nelem=/d' -e 's/^ \(..\)\(..\)\(..\)\(..\)$$/ \4\3\2\1/' | db_load-47
/var/lib/rpm/Packages
But still the error is the same:
# rpm -qa
rpmdb: unrecognized name-value pair: set_create_dir
rpmdb: unrecognized name-value pair: set_create_dir
error: db3open:db3.c:2318: dbenv->open(22): Invalid argument
error: cannot open Packages(0) index: Invalid argument(22)
DB: Berkeley DB 4.7.25: (May 15, 2008)
error: cannot open Packages database in /var/lib/rpm
I've built rpm 5.3.8 with db 4.7.
Thanks for your help,
Silvan
--
mambaSoft di Calarco Silvan
Web: http://www.mambasoft.it
mambaSoft Store @ http://www.mambastore.it
openmamba GNU/Linux development @ http://www.openmamba.org
______________________________________________________________________
RPM Package Manager http://rpm5.org
Developer Communication List [email protected]