zfs set running_with_scissors=on zroot

Zaphod Beeblebrox zbeeble at gmail.com
Mon Feb 16 22:41:03 UTC 2015


I've been struggling for awhile with zdb and friends recovering some data
from a curiously problematic old ZFS array and I had an idea:

Why not add a 'running_with_scissors' or maybe more properly named
'read_what_you_got_anyways' flag to zfs.

Maybe this produces some garbage for a problem file or maybe it doesn't  I
see two scenarios where this is useful:

1) where ZFS has declared an "error" somewhere where a scrub will
eventually remove that error.

2) where ZFS is having some sort of problem and the user just wants to try
pushing through it.

My concept of "how this would work" is that the flag would stop the
machinery that would normally stop the data from being delivered.

Note that case (1) might also be ameliorated by a flag or behavior that
rechecked only the blocks and checksums of data in question.  Right now, if
ZFS has "declared" something bad, it will return an error when you access
it --- even if a subsequent "scrub" would remove that flag --- that scrub
can take many, many hours.


More information about the freebsd-hackers mailing list