From owner-freebsd-fs@freebsd.org Sat Jul 15 13:53:15 2017 Return-Path: Delivered-To: freebsd-fs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8530AAFABD2 for ; Sat, 15 Jul 2017 13:53:15 +0000 (UTC) (envelope-from arcade@b1t.name) Received: from limbo.b1t.name (limbo.b1t.name [78.25.32.206]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 85BA170EB3 for ; Sat, 15 Jul 2017 13:53:12 +0000 (UTC) (envelope-from arcade@b1t.name) Received: from [172.29.1.236] (probe.42.lan [172.29.1.236]) by limbo.b1t.name (Postfix) with ESMTPSA id 2824183 for ; Sat, 15 Jul 2017 16:52:59 +0300 (EEST) Subject: Re: How can I recover data from a faulted pool? To: freebsd-fs References: <7e3d874e-e051-1169-2111-b8f2549f89ee@webmail.sub.ru> From: Volodymyr Kostyrko Message-ID: Date: Sat, 15 Jul 2017 16:52:58 +0300 User-Agent: Mozilla/5.0 (X11; DragonFly x86_64; rv:49.0) Gecko/20100101 Firefox/49.0 SeaMonkey/2.46 MIME-Version: 1.0 In-Reply-To: <7e3d874e-e051-1169-2111-b8f2549f89ee@webmail.sub.ru> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=b1t.name; s=dkim; t=1500126781; bh=geNB9pnpolWaJjGz23vxDktXy1xZGRx8+Pns4TEnAd0=; h=Subject:To:References:From:Message-ID:Date:MIME-Version:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=4Gc6x07IscSAbvAiEKO6eHQr/rk60caKZ5dGybF2VcemGyxqe8ExIYWlqkeJdpe9L+cKacj2TfQbkIayWnm0+p4fe4e6r2wxSx/Y2z4k9jIZH362Wif8vEOlxlu1v9gvuV6K5qExtb/drpRYVF9XRBHq3Ldd4eGZ6fZaCmlpBPo= X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Jul 2017 13:53:15 -0000 =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 recovere= d. > 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 errors > gpt/database1 FAULTED 0 0 0 too many errors > > disks can be read, can I somehow recover data from the pool? For sure... First please describe what happened to both disks and what=20 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=20 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=20 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=20 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=20 in r/o mode. If that would work, try mounting only required filesystem=20 and copy some data from it. Please post your results. --=20 Sphinx of black quartz judge my vow.