How to quickly determine if UFS2 FS is "clean" from command line?

Carlos A. M. dos Santos unixmania at gmail.com
Fri Dec 26 05:32:17 PST 2008


On Fri, Dec 26, 2008 at 11:20 AM, Sean <sean at gothic.net.au> wrote:
> Carlos A. M. dos Santos wrote:
>>
>> Be warned that file(1) resides at /usr/bin and depends on
>> /usr/share/misc/magic*, so it may not be available in early boot
>> stages, when /usr is not mounted yet. The following combination will
>> suffice, and depends only on /sbin and /stand:
>>
>>     /sbin/ffsinfo -l 1 /usr/local | /rescue/sed -n 's/^clean *int8_t
>> *\(.*\)/\1/p'
>>
>
> Except FreeBSD hasn't had /stand for a long while, and there's no
> /rescue/sed (at least on 6.x and 7.x). Also, /stand was only ever populated
> on install and there's no guarantees it was ever up to date.

Humm, 8.0 has /rescue/sed.

-- 
cd /usr/ports/sysutils/life
make clean


More information about the freebsd-hackers mailing list