Date: Wed, 31 Aug 2022 06:19:01 +0900 From: Tatsuki Makino <tatsuki_makino@hotmail.com> To: Kevin Oberman <rkoberman@gmail.com>, FreeBSD Ports ML <freebsd-ports@freebsd.org> Subject: Re: Recover from a corrupt pkg DB Message-ID: <PSAPR03MB56398D79D1B8F6288772DD7FFA799@PSAPR03MB5639.apcprd03.prod.outlook.com> In-Reply-To: <CAN6yY1vGf=LdXQ4DZjJRxho2t%2BNcGd0jt2-T7nhm84YjtCKN5g@mail.gmail.com> References: <CAN6yY1vGf=LdXQ4DZjJRxho2t%2BNcGd0jt2-T7nhm84YjtCKN5g@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello. I also just recently unlinked /var/db/pkg/local.sqlite to a place where it cannot be traced from the /var file system :) To recover from that, there should already be a backup that others have mentioned, in which case the following command is all that is needed to restore it. xzcat /var/backups/pkg.sql.xz | pkg shell Now all that is left is to re-install the port that was installed after that backup was made, and you will most likely be back to normal. After the backup is made, if the port tree is updated and there are any plist changes, no :) Regards.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?PSAPR03MB56398D79D1B8F6288772DD7FFA799>