Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Mar 2021 08:54:53 -0700
From:      Gary Aitken <freebsd@dreamchaser.org>
To:        Matthew Seaman <matthew@FreeBSD.org>, FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: installed ports library audit?
Message-ID:  <efddda4a-d2a6-a1ab-9b7f-0a03b8cba1e8@dreamchaser.org>
In-Reply-To: <0935eab6-d458-2c3e-3f8a-a6879fe27363@FreeBSD.org>
References:  <a99e82cc-da39-70e8-f3b1-7b250250876a@dreamchaser.org> <97db8511-c5e0-26cc-5e56-4dfa976d7d12@FreeBSD.org> <0935eab6-d458-2c3e-3f8a-a6879fe27363@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 3/1/21 8:38 AM, Matthew Seaman wrote:
> On 01/03/2021 15:36, Matthew Seaman wrote:
>> On 01/03/2021 03:43, Gary Aitken wrote:
>>> I just mostly recovered from a system crash where /usr was corrupted and
>>> had to be recovered using fsck; couldn't completely recover using the
>>> journal.
>>>
>>> I suspect the trashed files are in one of a few libraries.  I'm wondering
>>> if there's an easy way to audit all files installed by given ports,
>>> i.e. do an sha256 or something like that on each and compare with the known
>>> good if it's available somewhere?
<snip>
> Dammit. `pkg check -s -x .`
> 
> `-r` is exactly what you don't want, as that will make pkg(8) believe the corrupted files are actually correct.

Thanks, glad I went to bed before I saw the wrong one.  I read the man page
first but sometimes a in-a-hurry-to-get-things-done read misses things like
that.

Is there a similar check for the base system install?  I see security audits
but those are event related.

Gary




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?efddda4a-d2a6-a1ab-9b7f-0a03b8cba1e8>