pkg don't recognize installed packages
Matthew Seaman
m.seaman at infracaninophile.co.uk
Fri Apr 18 19:02:21 UTC 2014
On 18/04/2014 18:01, lokadamus at gmx.de wrote:
> System is 10.0-RELEASE-p1 (clean install in january) and last week all
> was working fine.
> In december i had trouble with /var/db/pkg/local.sqlite and had to
> remove it for a new one.
> This time this way isn't working. It creates a new local.sqlite, but
> dosn't recognize
> installed programs.
Right. This is obviously relevant information you might have considered
including in your original posting.
> Is there a command that pkg will reread all installed ports?
> Or can portmaster do this?
local.sqlite is *the* database of installed packages. If you destroy
it, there's nowhere else pkg(8) can get the information about what
packages are already installed. That's why there are periodic jobs to
take a backup each night, which you might find in /var/backups.
Hopefully it hasn't been so long that there is still useful data
preserved there.
Failing that, you will need to reinstall all your packages to repopulate
your package database.
Today's lesson is this: deleting the package database is not a good
idea. Two seconds to do, hours if not days to recover and forever
afterwards to regret.
Cheers,
Matthew
--
Dr Matthew J Seaman MA, D.Phil.
PGP: http://www.infracaninophile.co.uk/pgpkey
JID: matthew at infracaninophile.co.uk
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1036 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20140418/64998e61/attachment.sig>
More information about the freebsd-questions
mailing list