Discussion:
zpool replace for mirror vdev with spares
Evaldas Auryla
2013-09-17 15:58:58 UTC
Permalink
Hi everyone,

We've got into somewhat curious situation here with zpool replace, a
disk failed in 3 way mirror vdev - c6t4d0, the pool has 2 hot spares
c7t0d0 and c8t0d0, so it auto-resilvered with 1st spare c7t0d0. Next
morning we were to replace the failed disk with "zpool offline, cfgadm
unconfigure..", we then replaced physical disk and then did

zpool online cuve c6t4d0
zpool replace cuve c6t4d0

zfs started resilvering and then ended with following

mirror-6 DEGRADED 0 0 0
c5t4d0 ONLINE 0 0 0
spare-1 DEGRADED 0 0 0
replacing-0 DEGRADED 0 0 0
spare-0 DEGRADED 0 0 0
c6t4d0/old FAULTED 0 0 0 corrupted data
c8t0d0 ONLINE 0 0 0
c6t4d0 ONLINE 0 0 0
c7t0d0 ONLINE 0 0 0
c7t4d0 ONLINE 0 0 0
...
spares
c7t0d0 INUSE currently in use
c8t0d0 INUSE currently in use

Both spares are now in use.

Any advice what would be the best way to recover from this ?

Loading...