Re: (ZFS) zpool replace weirdness

From: Nathan Butcher <n-butcher_at_fusiongol.com>
Date: Tue, 24 Jul 2007 14:42:47 +0900
>I've been playing around with zfs for a bit, and ran into a problem
>where i corrupted an entire drive (on purpose) by way of dd
>if=/dev/urandom of=/dev/ad12 .. as expected, the zpool noticed:

I managed to do something similar, just not exactly the way you described.

For starters, I was unable to dd if=/dev/urandom of=/dev/ad3 because dd
prevented writing to the device in the zpool. What I did was to "zpool
export" my pool, THEN dd over the top of one of my devices. THEN "zpool
import" my pool again. The result was a fantastic error:-

  pool: z
 state: ONLINE
status: One or more devices could not be used because the label is
missing or
	invalid.  Sufficient replicas exist for the pool to continue
	functioning in a degraded state.
action: Replace the device using 'zpool replace'.
   see: http://www.sun.com/msg/ZFS-8000-4J
 scrub: resilver completed with 0 errors on Mon Jun 11 22:09:22 2007
config:

	NAME                     STATE     READ WRITE CKSUM
	z                        ONLINE       0     0     0
	  raidz1                 ONLINE       0     0     0
	    ad1                  ONLINE       0     0     0
	    4239271840293300479  UNAVAIL      0     0     0  was /dev/ad3
	    da0                  ONLINE       0     0     0
	    da1                  ONLINE       0     0     0

errors: No known data errors


Now I'm not sure how to recover the zpool. I can't exactly remove this
wonderful numerical device without a "ad3 is in use" error.

NB: that I'm running this ZFS on a 32-bit virtual machine with FreeBSD
i386 and 768MB memory. No idea if the problem replicates on amd64 with
over 1GB memory.
Received on Tue Jul 24 2007 - 03:42:51 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:15 UTC