]> git.ipfire.org Git - thirdparty/mdadm.git/commit - super1.c
Interpret "--metadata=1" with --assemble to imply any version-1, not just 1.0
authorDoug Ledford <dledford@redhat.com>
Sun, 8 Jul 2007 23:59:47 +0000 (09:59 +1000)
committerNeil Brown <neilb@suse.de>
Sun, 8 Jul 2007 23:59:47 +0000 (09:59 +1000)
commita17a3de364806681fc7c1395364d11061a638ff3
tree433defd8766ab620da6de85726e69c2c2dc24118
parent01d9299c1a1632b1be47dd6c9191b0e905928b2b
Interpret "--metadata=1" with --assemble to imply any version-1, not just 1.0

From: Doug Ledford <dledford@redhat.com>

OK, this one fixes an issue where people were doing manual array
creation and specifying superblock types other than 1.0 (aka, 1.1, 1.2)
and then using mdadm -Ebs to populate their mdadm.conf file.  The
general problem is that if you specify a superblock type in the ARRAY
line (or on the command line), then you must specify the superblock type
*exactly*, including the minor version.  Unfortunately, mdadm -Ebs
prints out all version 1 superblocks, regardless of minor version, as
just plain old 1.  This breaks the mdadm.conf file for anything other
than plain version 1 superblock devices.

So, since I thought it was basically backwards that the mdadm -E output
was lax on specifying the location of the superblock where as the mdadm
-A input was strict, I reversed that.  With this patch, the mdadm -E
output is now exact for any given superblock.  But, in addition, the
mdadm -A input is now lax for any superblock that doesn't specifically
list the minor version, aka version 1 now means version 1, not version
0.90, but any minor version.  So does default/large.
super1.c