Snag in upgrading p5-XML-SAX and p5-XML-SAX-Base

Matthew Seaman matthew at FreeBSD.org
Sat Oct 20 10:15:17 UTC 2012


On 20/10/2012 10:28, Thomas Mueller wrote:
> I just a day ago switched to pkgng, but "pkg delete" produced
> No package(s) found!
> 
>> did you run pkg2ng for it?
> 
> I remember running pkg2ng when switching to the new pkg.  Do I need to run
> pkg2ng again?
> 
> I now have /usr/bin/pkg and /usr/local/bin/pkg, and /usr/bin comes before
> /usr/local/bin in the PATH.

No -- you only ever need to run pkg2ng once.

/usr/bin/pkg will invoke /usr/local/bin/pkg automatically if
/usr/local/bin/pkg is installed -- /usr/bin/pkg is a shim that exists to
facilitate the installation of the actual /usr/local/bin/pkg binary.
That's all normal.

Now, the real problem: not seeing the contents of the local package
database.  Can you check a few things:

   1) That PKG_DBDIR isn't defined in your environment or in
      /usr/local/etc/pkg.conf  (or if it is, it is set to an
      appropriate directory.)

   2) That /var/db/pkg/local.sqlite exists and has these permissions
      and ownership:

% ls -l /var/db/pkg/local.sqlite
-rw-r--r--  1 root  wheel  4041728 Oct 14 17:52 /var/db/pkg/local.sqlite

      (The size will be different depending on what packages are
      installed)

   3) Try opening the local.sqlite database and investigating the
      contents of one or more of the tables. Like so:

# pkg shell
SQLite version 3.7.14.1 2012-10-04 19:37:12
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> select count(*) from packages ;
47
sqlite> .quit

       If that returns zero then something has wiped your package DB.
You may be able to recover from a backup copy of local.sqlite that the
daily periodic jobs creates in /var/backups/pkgng.db --  just copy that
back to /var/db/pkg/local.sqlite and try again.

    4) If there is content in local.sqlite, then try using 'pkg info' to
query the contents.  This should print out just about everything pkgng
knows about what is installed on your system:

    % pkg info -fa

	Cheers,

	Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.
PGP: http://www.infracaninophile.co.uk/pgpkey


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 264 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20121020/742aa53a/attachment.sig>


More information about the freebsd-ports mailing list