[Rpm-maint] RPM NDB and chroot failure
dvhart at infradead.org
Tue Jul 18 17:59:03 UTC 2017
While testing my previous patches to allow for an NDB only build of RPM, I ran
across an issue using the --root argument.
When passing --root, the strace log shows that after the chroot call, a stat()
of the Packages.db absolute path fails, which triggers a reopen, which fails as
it attempts open() using the absolute path.
This manifests in lib/backend/ndb/rpmpkg.c:
The pkgdb->filename is not being updated after chroot.
I'm looking into how to fix this, but I'm still a bit green on the RPM DB
Should the ndb implementation be using the rpmbd_internal API? For example,
rather than accessing pkgdb->filename directly, should the ndb implementation
have a call which provides it with the chroot adjusted path to the RPM DB?
Something using rpmdbHome() for example?
VMware Open Source Technology Center
More information about the Rpm-maint