summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeil Brown <neilb@suse.de>2006-10-10 07:06:24 +1000
committerNeil Brown <neilb@suse.de>2006-10-10 07:06:24 +1000
commitd2df86e0a79c1e3d86c19d6ecb14e6f303c5d50d (patch)
treedaf52a77f1b4560157c48bfa08bf51928972711c
parent45c073c921cfbfe23eaafa0b2bb0986e85e60e27 (diff)
downloadmdadm-d2df86e0a79c1e3d86c19d6ecb14e6f303c5d50d.tar.gz
mdadm-d2df86e0a79c1e3d86c19d6ecb14e6f303c5d50d.tar.xz
mdadm-d2df86e0a79c1e3d86c19d6ecb14e6f303c5d50d.zip
Improve the message when mdadm detects similar superblocks
If they are for a partition and a whole device (common case) they old message doesn't really cover the situation. So add the "overlap" option to the text. Also detect whether the device list was in mdadm.conf and act accordingly.
-rw-r--r--Assemble.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/Assemble.c b/Assemble.c
index 3c00c91..5acb076 100644
--- a/Assemble.c
+++ b/Assemble.c
@@ -531,9 +531,12 @@ int Assemble(struct supertype *st, char *mddev, int mdfd,
" to have very similar superblocks.\n"
" If they are really different, "
"please --zero the superblock on one\n"
- " If they are the same, please remove "
- "one from the list.\n",
- devices[best[i]].devname, devname);
+ " If they are the same or overlap,"
+ " please remove one from %s.\n",
+ devices[best[i]].devname, devname,
+ inargv ? "the list" :
+ "the\n DEVICE list in mdadm.conf"
+ );
if (must_close) close(mdfd);
return 1;
}