Page 1 of 1

Please help me fix my ZFS Pool!

Posted: 08 Aug 2016 13:29
by fallen2109
A cry for help - can someone let me know what commands shall I use to fix my ZFS pool. I refuses to mount due to
missing log partition - see below

nasvas1: ~# zpool import -f
pool: NASVAS1_DATA_VOL1
id: 7538559361031881166
state: DEGRADED
status: One or more devices are missing from the system.
action: The pool can be imported despite missing or damaged devices. The
fault tolerance of the pool may be compromised if imported.
see: http://illumos.org/msg/ZFS-8000-2Q
config:

NASVAS1_DATA_VOL1 DEGRADED
raidz1-0 ONLINE
da0 ONLINE
da1 ONLINE
da2 ONLINE
cache
5017906259124180018
logs
466764301866846062 UNAVAIL corrupted data

I do not know how to proceed further - tried to replace the corrupted data device, but to no success.
Please HELP

Re: Please help me fix my ZFS Pool!

Posted: 08 Aug 2016 15:16
by fallen2109
Fixed:

zpool create -f TEST /dev/ada0s3a
zpool destroy TEST
zpool import -m NASVAS1_DATA_VOL1
zpool replace -f NASVAS1_DATA_VOL1 466764301866846062 /dev/ada0s3a


I will never use a log device on a single um-mirrored partition. Lesson learned!

Re: Please help me fix my ZFS Pool!

Posted: 08 Aug 2016 20:27
by substr
The -m is probably what worked.

You can do a proper removal of the log device once the pool is imported, if it still shows up. There is nothing wrong with using a log that isn't mirrored, but you do need to know about the -m flag if you ever lose the log device.

You might also want to remove the cache device, since it is unclear whether a bug involving L2ARC still exists. (See the recent thread viewtopic.php?f=66&t=11163)