From owner-freebsd-stable@FreeBSD.ORG Sun Jun 2 14:12:02 2013 Return-Path: <owner-freebsd-stable@FreeBSD.ORG> Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id A20F4FAD for <freebsd-stable@freebsd.org>; Sun, 2 Jun 2013 14:12:02 +0000 (UTC) (envelope-from kpaasial@gmail.com) Received: from mail-qa0-x235.google.com (mail-qa0-x235.google.com [IPv6:2607:f8b0:400d:c00::235]) by mx1.freebsd.org (Postfix) with ESMTP id 696CD13A8 for <freebsd-stable@freebsd.org>; Sun, 2 Jun 2013 14:12:02 +0000 (UTC) Received: by mail-qa0-f53.google.com with SMTP id bs12so1330508qab.5 for <freebsd-stable@freebsd.org>; Sun, 02 Jun 2013 07:12:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=+1rN9gx5SklWjPQnF5NGq6dc5tnOBYjJxZz3H6mthYw=; b=DoG9Hy1aDqqrKiH949PIJR33uppcqYKxTy8xwbIcdNiwjfPlIoOpCweyPr6OQODbmw ZDd7FAzVXlNKiOUwoV3Gx6ioArmHOFKgrWpePnWuZHsiW2uviyGSQtlSHzVN/M8svndd ltPCMafpHOvGyp7hKifIy9kNXWXYuDmcM2CzyNShMAq4d1UJ2yWwX0n9O8ZxL4G7Dbiu XBMeEC2Y3mh1b6WGA9O+TTEbZVF6uXtj+uTOxx1MxhxXZ8BvOMt1G2tFAfEz9HCQi08+ XYEsJ+a+XyA1Ld2Lol3Kyyrbm0YpXTcnSsrLetAIXI4dULPHd6Zs4Sdqw1NcVWze4sVc NFvg== MIME-Version: 1.0 X-Received: by 10.49.120.198 with SMTP id le6mr17672677qeb.59.1370182321973; Sun, 02 Jun 2013 07:12:01 -0700 (PDT) Received: by 10.224.3.72 with HTTP; Sun, 2 Jun 2013 07:12:01 -0700 (PDT) In-Reply-To: <7ABBEE71A96E411793E41BD97DA72BCE@multiplay.co.uk> References: <EA2DCEC2-8B07-434B-8B60-8AB15B3788F7@gmail.com> <7ABBEE71A96E411793E41BD97DA72BCE@multiplay.co.uk> Date: Sun, 2 Jun 2013 17:12:01 +0300 Message-ID: <CA+7WWSe7O9+xq3UEJ++tM1d3tphf7pWU=n4DoQY8XZq39RRScQ@mail.gmail.com> Subject: Re: Corrupt GPT header on disk from twa array - fixable? From: Kimmo Paasiala <kpaasial@gmail.com> To: Alban Hertroys <haramrae@gmail.com> Content-Type: text/plain; charset=UTF-8 Cc: freebsd-stable@freebsd.org, Steven Hartland <killing@multiplay.co.uk> X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Production branch of FreeBSD source code <freebsd-stable.freebsd.org> List-Unsubscribe: <http://lists.freebsd.org/mailman/options/freebsd-stable>, <mailto:freebsd-stable-request@freebsd.org?subject=unsubscribe> List-Archive: <http://lists.freebsd.org/pipermail/freebsd-stable> List-Post: <mailto:freebsd-stable@freebsd.org> List-Help: <mailto:freebsd-stable-request@freebsd.org?subject=help> List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-stable>, <mailto:freebsd-stable-request@freebsd.org?subject=subscribe> X-List-Received-Date: Sun, 02 Jun 2013 14:12:02 -0000 On Sun, Jun 2, 2013 at 5:02 PM, Steven Hartland <killing@multiplay.co.uk> wrote: > Does "gpart recover ada4" help at all? > > Be warned this could edit the partition on the disk and make it worse, but > I've had success in the past with it. > > Regards > Steve > > ----- Original Message ----- From: "Alban Hertroys" <haramrae@gmail.com> > To: <freebsd-stable@freebsd.org> > Sent: Sunday, June 02, 2013 2:53 PM > Subject: Corrupt GPT header on disk from twa array - fixable? > > > >> Hello list, >> >> I just replaced my home server and moved the disks from the old one over >> to the new one. In the old server, 4 of the disks were connected to a twa >> (3Ware 9550) controller, which of course has it's own way of marking >> units/volumes on those disks. >> >> Before you start yelling at me, yes, of course I made backups ;) [*] >> >> The thing is, I have these disks in the new server and I found that I (to >> my surprise) I can actually mount them! But, I'm missing a large part and I >> am wondering if there's some method to access those last partitions too. >> >> Here's what gpart show says about the problematic disk: >> >> # gpart show /dev/ada4 >> => 34 41942972 ada4 GPT (931G) [CORRUPT] >> 34 128 1 freebsd-boot (64k) >> 162 1048448 2 freebsd-ufs (512M) >> 1048610 6291456 3 freebsd-swap (3.0G) >> 7340066 1048576 4 freebsd-ufs (512M) >> 8388642 2097152 5 freebsd-ufs (1.0G) >> 10485794 31457211 6 freebsd-ufs (15G) >> 41943005 1 - free - (512B) >> >> As you can see, most (about 910GB) of the disk is missing! This disk was >> one half of a mirror on the twa controller, which had those disks split in >> two again (I don't recall how, perhaps 2 different BSD slices?) >> I already looked if that part may perhaps have ended up as a different >> device. On the old server, fstab was this: >> >> # cat /tmp/solfertje/etc/fstab >> # Device Mountpoint FStype Options Dump Pass# >> >> # These are the partitions listed above in gpart >> /dev/da0p2 / ufs rw 1 1 >> /dev/da0p3 none swap sw 0 0 >> /dev/da0p4 /var ufs rw 2 2 >> /dev/da0p5 /tmp ufs rw 2 2 >> /dev/da0p6 /usr ufs rw 2 2 >> >> # These are missing >> /dev/da1p1 /home ufs rw 2 2 >> /dev/da1p2 /media ufs rw 2 2 >> >> # These are on a different disk (ada2) >> /dev/da2p1 /media2 ufs rw 2 2 >> >> >> I don't _really_ need to get to those partitions, but it would be a >> comfortable thought if it were possible somehow. >> >> >> [*] The reason I was trying to access those disks anyway is that I thought >> I forgot to backup my database tables, but it turns out I had just misplaced >> that backup and it has been restored now. >> >> Alban Hertroys >> -- >> If you can't see the forest for the trees, >> cut the trees and you'll find there is no forest. >> >> _______________________________________________ >> freebsd-stable@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-stable >> To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" >> > > Looking at the gpart(8) output it seems that only 20GBs of the disk is recognized by the disk driver but the GPT table still shows the full capacity 910GB. I'd say that the GPT table is in fact correct and if you can somehow get the disks to be recognized with full capacity they should be usable as they are. What does dmesg(8) say about the disks? -Kimmo