Re: How to recreate a dmraid RAID array with mdadm
On Wed, 17 Nov 2010 21:05:40 -0500
Mike Viau <viaum@sheridanc.on.ca> wrote:
> ./mdadm -Ss
>
> mdadm: stopped /dev/md127
>
>
> ./mdadm -Asvvv
>
> mdadm: looking for devices for further assembly
> mdadm: no RAID superblock on /dev/dm-3
> mdadm: /dev/dm-3 has wrong uuid.
> want UUID-084b969a:0808f5b8:6c784fb7:62659383
> Segmentation fault
Try this patch instead please.
NeilBrown
diff --git a/Assemble.c b/Assemble.c
index afd4e60..11e6238 100644
--- a/Assemble.c
+++ b/Assemble.c
@@ -344,9 +344,17 @@ int Assemble(struct supertype *st, char *mddev,
if (ident->uuid_set && (!update || strcmp(update, "uuid")!= 0) &&
(!tst || !tst->sb ||
same_uuid(content->uuid, ident->uuid, tst->ss->swapuuid)==0)) {
- if (report_missmatch)
+ if (report_missmatch) {
+ char buf[200];
fprintf(stderr, Name ": %s has wrong uuid.\n",
devname);
+ fprintf(stderr, " want %s\n", __fname_from_uuid(ident->uuid, 0, buf, ':'));
+ fprintf(stderr, " tst=%p sb=%p\n", tst, tst?tst->sb:NULL);
+ if (tst) {
+ fprintf(stderr, " have %s\n", __fname_from_uuid(content->uuid, 0, buf, ':'));
+ fprintf(stderr, " metadata=%s\n", tst->ss->name);
+ }
+ }
goto loop;
}
if (ident->name[0] && (!update || strcmp(update, "name")!= 0) &&
Reply to: