From owner-freebsd-questions@FreeBSD.ORG Tue Mar 31 14:59:14 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E035E10656BB for ; Tue, 31 Mar 2009 14:59:13 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 5D5D28FC17 for ; Tue, 31 Mar 2009 14:59:12 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1LofQl-0005G4-Hk for freebsd-questions@freebsd.org; Tue, 31 Mar 2009 14:59:11 +0000 Received: from lara.cc.fer.hr ([161.53.72.113]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 31 Mar 2009 14:59:11 +0000 Received: from ivoras by lara.cc.fer.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 31 Mar 2009 14:59:11 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Ivan Voras Date: Tue, 31 Mar 2009 16:58:54 +0200 Lines: 71 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig10C673B86B49F7293B852E52" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: lara.cc.fer.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090318) In-Reply-To: X-Enigmail-Version: 0.95.0 Sender: news Subject: Re: Recovering a GEOM RAID0 array X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 31 Mar 2009 14:59:14 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig10C673B86B49F7293B852E52 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Juan Miscaro wrote: >> It looks like you created a both a fdisk partition table and a bsdlabe= l >> partition table on the ad3 drive. If so, your data is probably already= >> corrupted. >=20 > What is a generic configuration? Or can you explain how you come to > that conclusion? RAID 0 means striping data across N drives (2 in your case), with a fixed stripe size. From the information in kern.geom.confxml (which is why gstripe list should work), your stripe size is 4 kB, which is good for this purpose. This kind of setup is usually done with raw drives, i.e. with GEOM_STRIPE: "gstripe label st0 ad1 ad3". After this, your array is called stripe/st0 - this is where you create the file system, etc. "Striping" means that each drive contains only a part of the data. E.g. if you write 8 kB to the start of your array, the first 4 kB will be written to ad1, the next 4 kB to ad3. Both smaller and larger requests are handled logically. This means that the first sector on ad1 contains the partition table of your array, if you partitioned it (and it looks like you did). The first sector of ad3 contains whatever data is at position 4096 in your array - probably nothing important because your partitions start at 32 kB - 512. If you wrote only the partition table to ad3 then it's not a big deal - it's useless but it may not corrupt anything important. If you proceeded to to something else on ad3, then there could be problems. >> ad1 is also strangely partitioned but since it's your first drive in a= >> stripe this can be acceptable (it will contain the first sectors of th= e >> array, including its partition tables). >> >>> # gstripe dump ad3 >>> Can't read metadata from ad3: Invalid argument. >>> Not fully done. >> This can happen if the metadata on ad3 is corrupted. You'll need to du= mp >> the last sector and inspect it to verify. >=20 > I've never done that before. Can you be explicit? Using information from your previous posts, you should do this: # dd if=3D/dev/ad3 of=3Dad3last count=3D1 skip=3D625142447 # hd ad3last --------------enig10C673B86B49F7293B852E52 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFJ0i+uldnAQVacBcgRAonGAJ9RW48bA+uETfhtsGzX78yziWwKwgCg54wF zYXtqer6mY+p4csDtrCUA5w= =qdEq -----END PGP SIGNATURE----- --------------enig10C673B86B49F7293B852E52--