Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Jul 2017 22:42:24 +0300
From:      Volodymyr Kostyrko <arcade@b1t.name>
To:        freebsd-fs@freebsd.org
Subject:   Re: How can I recover data from a faulted pool?
Message-ID:  <a0ce2d74-dad5-27bd-fa1d-6a66720b2522@b1t.name>
In-Reply-To: <ce16cbec-71a1-e615-26fc-fec5a6ac282d@webmail.sub.ru>
References:  <7e3d874e-e051-1169-2111-b8f2549f89ee@webmail.sub.ru> <b7c3f089-963d-a23a-7bbe-ab1a450acd27@b1t.name> <ce16cbec-71a1-e615-26fc-fec5a6ac282d@webmail.sub.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B0=D0=BD=D0=B4=D1=80 =D0=9F=D0=BE=D0=B2=
=D0=BE=D0=BB=D0=BE=D1=86=D0=BA=D0=B8=D0=B9 wrote:
> Everything is fine. The problem was in mounting order, so I did not see=

> files. And I could not think properly because of tooth pain))

Yeah, maybe I hadn't pointed that out properly but you will get pool=20
imported but no filesystems mounted. This can help in case when some fs=20
is badly damaged and triggers assert on mount. So you will still need to =

mount required fs by hand.

>
>
> 15.07.2017 16:52, Volodymyr Kostyrko =D0=BF=D0=B8=D1=88=D0=B5=D1=82:
>> =D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B0=D0=BD=D0=B4=D1=80 =D0=9F=D0=BE=D0=
=B2=D0=BE=D0=BB=D0=BE=D1=86=D0=BA=D0=B8=D0=B9 wrote:
>>> Hello
>>>
>>> FreeBSD 10.3. ZFS.
>>>
>>>  # zpool status
>>>   pool: database
>>>  state: UNAVAIL
>>> status: One or more devices are faulted in response to persistent
>>> errors.  There are insufficient replicas for the pool to
>>>         continue functioning.
>>> action: Destroy and re-create the pool from a backup source. Manually=

>>> marking the device
>>>         repaired using 'zpool clear' may allow some data to be
>>> recovered.
>>>   scan: none requested
>>> config:
>>>
>>>         NAME               STATE     READ WRITE CKSUM
>>>         database           UNAVAIL      0     0     0
>>>           mirror-0         UNAVAIL      0     0     0
>>>             gpt/database0  FAULTED      0     0     0  too many error=
s
>>>             gpt/database1  FAULTED      0     0     0  too many error=
s
>>>
>>> disks can be read, can I somehow recover data from the pool?
>>
>> For sure... First please describe what happened to both disks and what=

>> hardware you were using (chipset/controller). Please don't try to
>> `zpool clear` yet.
>>
>> 1. ZFS *HEAVILY* relies on hardware to be stable, any hardware
>> glitches may result in severe pool corruption. If you have any doubts
>> in hardware first move the disks to the trusted box.
>>
>> 2. I assume both mirror parts were on different disks? ZFS doesn't
>> like pools that have more then one chunk on any drive.
>>
>> 3. Try mounting pool R/O with transaction recovery. While this is
>> mirror please do this for both disks and give it another try for
>> single disks as results may differ:
>>
>> `zpool import -N -O readonly=3Don -f -R /mnt/somezpoool =E2=80=A6`
>>
>> You can use mfsBSD for that.
>>
>> If that doesn't help try:
>>
>> `zpool import -N -O readonly=3Don -f -R /mnt/somezpoool -Fn =E2=80=A6`=

>>
>> Both commands will try to import the pool without mounting file
>> systems in r/o mode. If that would work, try mounting only required
>> filesystem and copy some data from it.
>>
>> Please post your results.
>>
>
> _______________________________________________
> freebsd-fs@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-fs
> To unsubscribe, send any mail to "freebsd-fs-unsubscribe@freebsd.org"


--=20
Sphinx of black quartz judge my vow.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a0ce2d74-dad5-27bd-fa1d-6a66720b2522>