From: Neil Brown <neilb@suse.de>
To: Anshuman Aggarwal <anshuman@brillgene.com>
Cc: linux-raid@vger.kernel.org
Subject: Re: linux raid recreate
Date: Wed, 7 Apr 2010 08:55:45 +1000 [thread overview]
Message-ID: <20100407085545.7673be70@notabene.brown> (raw)
In-Reply-To: <B3E0E48F-88C0-4D6F-8E23-B1344BC1C82C@brillgene.com>
On Tue, 6 Apr 2010 23:37:02 +0530
Anshuman Aggarwal <anshuman@brillgene.com> wrote:
> I've just had to recreate my raid5 device by using
> mdadm --create --assume-clean -n4 -l5 -e1.2 -c64
>
> in order to recover my data (because --assemble would not work with force etc.).
> The problem:
> * Data Offset in the new array is much larger.
> * Internal Bitmap is starting at a different # sectors from superblock.
> * Array Size is smaller though the disks are the same.
>
> How can I get these to be the same as what they were in the original array???
Use the same version of mdadm and you used to originally create the array.
Probably 2.6.9 from the data, though 3.1.1 seems to create the same layout.
So anything before 3.1.2
I really should write a "--recreate" for mdadm which uses whatever parameters
if it finds already on the devices.
NeilBrown
>
> I have tried to make sure that nothing gets written to the md device except the metadata during create.
> All of these are important because the fs on top of the LVM on top of the md would need all the data it can to fsck properly and I don't want it starting on the wrong offset.
>
> I am including the output from mdadm --examine from before and after the create
>
> Originally...
>
> >>> /dev/sdb5:
> >>> Magic : a92b4efc
> >>> Version : 1.2
> >>> Feature Map : 0x1
> >>> Array UUID : 42c56ea0:2484f566:387adc6c:b3f6a014
> >>> Name : GATEWAY:127 (local to host GATEWAY)
> >>> Creation Time : Sat Aug 22 09:44:21 2009
> >>> Raid Level : raid5
> >>> Raid Devices : 4
> >>>
> >>> Avail Dev Size : 586099060 (279.47 GiB 300.08 GB)
> >>> Array Size : 1758296832 (838.42 GiB 900.25 GB)
> >>> Used Dev Size : 586098944 (279.47 GiB 300.08 GB)
> >>> Data Offset : 272 sectors
> >>> Super Offset : 8 sectors
> >>> State : clean
> >>> Device UUID : f8ebb9f8:b447f894:d8b0b59f:ca8e98eb
> >>>
> >>> Internal Bitmap : 2 sectors from superblock
> >>> Update Time : Fri Mar 19 00:56:15 2010
> >>> Checksum : 1005cfbc - correct
> >>> Events : 3796145
> >>>
> >>> Layout : left-symmetric
> >>> Chunk Size : 64K
> >>>
> >>> Device Role : Active device 2
> >>> Array State : .AA. ('A' == active, '.' == missing)
>
> New...
>
> /dev/sdb5:
> Magic : a92b4efc
> Version : 1.2
> Feature Map : 0x1
> Array UUID : 8588b69c:c0579680:8a63486a:cbcb0e7d
> Name : GATEWAY:511 (local to host GATEWAY)
> Creation Time : Tue Apr 6 01:53:25 2010
> Raid Level : raid5
> Raid Devices : 4
>
> Avail Dev Size : 586097284 (279.47 GiB 300.08 GB)
> Array Size : 1758290688 (838.42 GiB 900.24 GB)
> Used Dev Size : 586096896 (279.47 GiB 300.08 GB)
> Data Offset : 2048 sectors
> Super Offset : 8 sectors
> State : clean
> Device UUID : 13d6a075:c1cad6dc:c13c3d98:e4b980e9
>
> Internal Bitmap : 8 sectors from superblock
> Update Time : Tue Apr 6 23:23:07 2010
> Checksum : df3cb34f - correct
> Events : 4
>
> Layout : left-symmetric
> Chunk Size : 64K
>
> Device Role : Active device 2
> Array State : .AAA ('A' == active, '.' == missing)
>
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-04-06 22:55 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <S1753093Ab0CYHZE/20100325072504Z+37@vger.kernel.org>
2010-03-25 9:30 ` 4 partition raid 5 with 2 disks active and 2 spare, how to force? Anshuman Aggarwal
2010-03-25 11:37 ` Michael Evans
2010-03-25 14:09 ` Anshuman Aggarwal
2010-03-26 3:38 ` Michael Evans
2010-03-26 16:28 ` Anshuman Aggarwal
2010-03-26 19:04 ` Michael Evans
2010-03-28 15:18 ` Anshuman Aggarwal
2010-03-28 16:35 ` Anshuman Aggarwal
2010-03-29 5:32 ` Luca Berra
2010-03-29 6:41 ` Michael Evans
2010-04-06 18:07 ` linux raid recreate Anshuman Aggarwal
2010-04-06 22:55 ` Neil Brown [this message]
2010-04-07 0:24 ` Berkey B Walker
2010-04-07 7:27 ` Anshuman Aggarwal
2010-04-07 13:15 ` Neil Brown
2010-03-26 19:29 ` 4 partition raid 5 with 2 disks active and 2 spare, how to force? John Robinson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100407085545.7673be70@notabene.brown \
--to=neilb@suse.de \
--cc=anshuman@brillgene.com \
--cc=linux-raid@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).