From owner-freebsd-fs@FreeBSD.ORG Wed Apr 17 18:53:41 2013 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id C22DE752 for ; Wed, 17 Apr 2013 18:53:41 +0000 (UTC) (envelope-from amvandemore@gmail.com) Received: from mail-wi0-x234.google.com (mail-wi0-x234.google.com [IPv6:2a00:1450:400c:c05::234]) by mx1.freebsd.org (Postfix) with ESMTP id 62EEBEE4 for ; Wed, 17 Apr 2013 18:53:41 +0000 (UTC) Received: by mail-wi0-f180.google.com with SMTP id h11so808993wiv.7 for ; Wed, 17 Apr 2013 11:53:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=TApCRvhVSbH/UbSTa5Mv0Ukm6f0W3ooKESoWZZQJS1o=; b=Bj5gm4i4RvL+O9H/nND0vM0NSZ25VL3Bf51gMFv09s57dahihCfcAxWWcBiCkQdNzE jG7MIAKW8LKY6a8zhIOdSRS5xujzgFW244CGc9pN63K8EPPcXrWA+zvqM83qt85Byon9 VD7vU3bdcQqnyFeiuN4M41XjeyLFATvvNXTH43khjTCCIDRQmeA4R156CSjRFZgg3ZPc 67l+Y42UemA05IiAQoLinQP+J843kzzsU+bWcdEkybHV10m06DJGOc/VXSz/mlBM2Kct 102YxRdf/JdkQ7DXol75HW8g7ICVlYacXx8HgWYgC1qxQksmi7FIaWqHW+59wMPeR3wj kBIw== MIME-Version: 1.0 X-Received: by 10.194.176.165 with SMTP id cj5mr13527854wjc.37.1366224820552; Wed, 17 Apr 2013 11:53:40 -0700 (PDT) Received: by 10.194.242.101 with HTTP; Wed, 17 Apr 2013 11:53:40 -0700 (PDT) In-Reply-To: <1366221907838-5804517.post@n5.nabble.com> References: <1366221907838-5804517.post@n5.nabble.com> Date: Wed, 17 Apr 2013 13:53:40 -0500 Message-ID: Subject: Re: [ZFS] recover destroyed zpool with ZDB From: Adam Vande More To: Beeblebrox Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: freebsd-fs X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Apr 2013 18:53:41 -0000 On Wed, Apr 17, 2013 at 1:05 PM, Beeblebrox wrote: > I destroyed my zpool but forgot to take the tar backup of /home folder. > This > was a single-HDD pool and I first did 'zpool destroy' then 'gpart destroy' > before realizing my error. > > Since then, I have manually re-created the GPT partitions to the size they > were (testdisk did not correctly identify the geom) and there have been no > writes to the HDD. > > After a lengthly discussion here: > > http://freebsd.1045724.n5.nabble.com/ZFS-recover-destroyed-zpool-what-are-the-available-options-td5800299.html > and getting no result with: > # zpool import -D -f -R /bsdr -N -F -X 12018916494219117471 rescue => > cannot import 'bsdr' as 'rescue': no such pool or dataset. Destroy and > re-create the pool from a backup source. > > I sent an email to an expert and was advised to look into zdb and the -F & > -X flags. Good news and bad news there. '# zdb -e -F 12018916494219117471' > gives a lot of output but this is conflicting because although there are no > errors, %used is showing zero: > One thing is that you keep using zpool import -D when the pool isn't in a destroyed state. -- Adam Vande More