From owner-freebsd-questions@FreeBSD.ORG Sat Jan 19 15:01:32 2013 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id D0850EF6 for ; Sat, 19 Jan 2013 15:01:32 +0000 (UTC) (envelope-from bob@immure.com) Received: from maul.immure.com (adsl-66-136-206-1.dsl.austtx.swbell.net [66.136.206.1]) by mx1.freebsd.org (Postfix) with ESMTP id 35115EF9 for ; Sat, 19 Jan 2013 15:01:31 +0000 (UTC) Received: from rancor.immure.com (rancor.immure.com [10.1.132.9]) by maul.immure.com (8.14.5/8.14.5) with ESMTP id r0JF0vVi049690; Sat, 19 Jan 2013 09:00:57 -0600 (CST) (envelope-from bob@immure.com) Received: from rancor.immure.com (localhost [127.0.0.1]) by rancor.immure.com (8.14.6/8.14.6) with ESMTP id r0JF0ve1007934; Sat, 19 Jan 2013 09:00:57 -0600 (CST) (envelope-from bob@rancor.immure.com) Received: (from bob@localhost) by rancor.immure.com (8.14.6/8.14.6/Submit) id r0JF0vwV007933; Sat, 19 Jan 2013 09:00:57 -0600 (CST) (envelope-from bob) Date: Sat, 19 Jan 2013 09:00:57 -0600 From: Bob Willcox To: "illoai@gmail.com" Subject: Re: Safe way to repair corrupted GPT partition table? Message-ID: <20130119150057.GB7788@rancor.immure.com> References: <20130118200824.GA4084@rancor.immure.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-immure-MailScanner-Information: Please contact the ISP for more information X-immure-MailScanner-ID: r0JF0vVi049690 X-immure-MailScanner: Found to be clean X-immure-MailScanner-SpamCheck: not spam (whitelisted), SpamAssassin (not cached, score=-2.9, required 1, autolearn=not spam, ALL_TRUSTED -1.00, BAYES_00 -1.90) X-immure-MailScanner-From: bob@immure.com X-Spam-Status: No Cc: questions list X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Bob Willcox List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Jan 2013 15:01:32 -0000 On Fri, Jan 18, 2013 at 07:40:59PM -0500, illoai@gmail.com wrote: > On 18 January 2013 15:08, Bob Willcox wrote: > > Is there a way to repair a GPT partition table that has gotten corrupted > > (following a system hang during heavy I/O to a ZFS filesystem)? > > > > I now get these errors whenever I boot the system: > > > > GEOM: da0: corrupt or invalid GPT detected. > > GEOM: da0: GPT rejected -- may not be recoverable. > > > > Fortunately, my ZFS filesystem on the disk (actually a RAID 5 array on a > > ARC-1223 adapter) still mounts and seems to be ok. There is only one partition > > on the disk (the ZFS one) and it covered the entire disk so restoring it > > should be easy. Question is, is there a way to do this and will it be safe (I > > wouldn't want to trash the filesystem in the partion). > > > > A 'gpart show da0' gives this result: > > > > gpart: No such geom: da0. > > > > This is on a 9.1-STABLE system: > > > > FreeBSD rancor.immure.com 9.1-STABLE FreeBSD 9.1-STABLE #2 r245176: Tue Jan 8 15:45:29 CST 2013 bob@amidala.immure.com:/usr/obj/usr/src/sys/AMIDALA amd64 > > > > > > Any help would be much appreciated. > > > > Is the whole disk in the zfs pool, or is this a > single partition covering the whole disk that > has been placed in the zfs pool? It is a single partition covering the entire disk. > > Have you tried to repair it with the zfs tools? No, not sure what to try. I'm fairly new to zfs. Thanks, Bob > > -- > -- -- Bob Willcox | LIVING YOUR LIFE: bob@immure.com | A task so difficult, it has never been attempted before. Austin, TX |