zpool destroy causes panic

Dan Langille dan at langille.org
Sun Jul 25 21:01:08 UTC 2010


On 7/25/2010 4:49 PM, Volodymyr Kostyrko wrote:
> 25.07.2010 20:58, Dan Langille wrote:
>> NAME STATE READ WRITE CKSUM
>> storage ONLINE 0 0 0
>> raidz2 ONLINE 0 0 0
>> gpt/disk01 ONLINE 0 0 0
>> gpt/disk02 ONLINE 0 0 0
>> gpt/disk03 ONLINE 0 0 0
>> gpt/disk04 ONLINE 0 0 0
>> gpt/disk05 ONLINE 0 0 0
>> /tmp/sparsefile1.img UNAVAIL 0 0 0 corrupted data
>> /tmp/sparsefile2.img UNAVAIL 0 0 0 corrupted data
>
> 0k, i'll try it from here. UNAVAIL means ZFS can't locate correct vdev
> for this pool member. Even if this file exists it's not used by ZFS
> because it lacks ZFS headers/footers.
>
> You can (I think so) reinsert empty file to the pool with:
>
> # zpool replace storage /tmp/sparsefile1.img /tmp/sparsefile1.img
>
> ^- pool ^- ZFS old vdev name ^- current file
>
> If you replace both files you can theoretically bring pool to fully
> consistent state.
>
> Also you can use md to convert files to devices:
>
> # mdconfig -a -t vnode -f /tmp/sparsefile1.img
> md0
>
> And you can use md0 with your pool.

FYI, tried this, got a panic:

errors: No known data errors
# mdconfig -a -t vnode -f /tmp/sparsefile1.img
md0
# mdconfig -a -t vnode -f /tmp/sparsefile2.img
md1
# zpool replace storage /tmp/sparsefile1.img /dev/md0


-- 
Dan Langille - http://langille.org/


More information about the freebsd-stable mailing list