NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: /usr/pkg/lib/libgobject-2.0.so.8: Shared object "libffi.so.8" not found



On Mon, Mar 07, 2022 at 09:04:19AM -0500, Greg Troxel wrote:

Bruce Nagel <nagelbh%sdf.org@localhost> writes:

Looking through the 'pkgdb-change' page, I'm missing 2 of the 3 files

/etc/mk.conf has:
PKG_DBDIR=/var/db/pkg

so that line just needs to be changed to:
PKG_DBDIR=/usr/pkg/pkgdb

I have no /etc/pkg_install.conf file or /usr/pkg/etc/pkg_install.conf -
should I create them and just include PKG_DBDIR=/usr/pkg/pkgdb in them?
Or do I need to do something more (is there other content needed in
those files)?

I would say yes, and then all the tools should agree on the pkgdb.

pkg_admin check:   pkg_admin can't open
/var/db/pkg/gdk-pixbuf2-2.40.0nb2/+CONTENTS: No such file or directory

Start looking at the pkgdb, both of them.  Learn what normal packages
look like.  If there is a dir with no control files, just remove it.

pkg_admin rebuild-tree:   pkg_admin: Cannot read +CONTENTS of package
gdk-pixbuf2-2.40.0nb2

Same problem as above.

_NetBSD-pkgdb check found:  FATAL: TWO copies of PKG_DBDIR found

So it's definitely the split-brain package databases problem.

/usr/sbin/pkg_add -V gives:   20191008

/usr/sbin/pkg/pkg_add -V gives:   20210308

Do I need to fix anything there?

probably not, except that updating the base system to 9.2 is probably a
good idea.  But with the PKG_DBDIR lines it should be ok.


So you need to dig in and see what is in both databases, and probably
you can move the dirs from /var/db/pkg to /usr/pkg/pkgdb or the other
way around (either is ok, but you must have 1 and you must have all 3
configs pointing to the chosen one.  I prefer /usr/pkg/pkgdb at this
point.)   This is sort of a manual merge process.

Then the script should fix up the embeedded paths.  Read and understand
the script - I tried to comment it well.



I made sure all 3 places had the some /PKG_DBDIR=/usr/pkg/pkgdb in them.

I did the 'manual merge' from /var/db/pkg and /var/db/pkg.refcount to
/usr/pkg/pkgdb and /usr/pkg/pkgdb.refcount.  I removed the older
versions of duplicates in /usr/pkg/pkgdb.  I removed the old /var/db/pkg
and /var/db/pkg.refcount directories.

I ran the script with 'check' and it found no problems.

I ran the script with 'migrate' and it reported no problems after
running.

pkg_admin check complains about failing md5 checksums for a variety of
things including the libffi that's been an issue all through this.

pkg_admin rebuild-tree complains about not being able to read the
+CONTENTS of gdk-pixbuf2-2.40.0nb2

pkgin appears to update and appears to install e.g., vim but vim does
not get installed, isn't in /usr/pkg/bin, it still doesn't appear to
actually do anything.


What do I investigate or try next?

Thanks,
Bruce
--
+



Home | Main Index | Thread Index | Old Index