[Tux3] Review incoming changes
Mike Snitzer
snitzer at gmail.com
Tue Dec 16 10:03:42 PST 2008
On Tue, Dec 16, 2008 at 5:21 AM, Daniel Phillips <phillips at phunq.net> wrote:
> On Tuesday 16 December 2008 01:48, OGAWA Hirofumi wrote:
>> > Clear the existent magic first, then overwrite:
>> >
>> > Yes, more sensible. Does MD really want us to clear 64 KB at the top
>> > of the volume? That would seem rather sloppy of MD. Really, it
>> > should rely on the just the final sector of a volume to know if it
>> > is an MD volume.
>>
>> IIRC, MD RAID is using final 64kb. I think we should clear the top
>> 1024bytes and final 64kb. (And with it, to make sure, we would check if
>> volume size is bigger than 64kb, instead of clearing 64kb blindly.)
>
> Here is the full story about md superblock:
>
> http://lxr.linux.no/linux+v2.6.27/include/linux/raid/md_p.h#L19
>
> As I read it, the MD superblock can be as much as 128K less a byte
> below the top of the volume. It only actually uses 4K, and places that
> 4K at a silly place for no apparent reason. This is really sloppy,
> gross, disgusting, all that. But it is also existing practice. On the
> other hand, if everybody has been thinking the md superblock is in the
> top 64K and it actually isn't, do we do any harm by not attempting to
> clear it? I think clearing out the space below our superblock (which
> we have obligingly left free in case somebody needs to put a partition
> block there) is a really good idea, but not so sure about the md stuff
> at the top.
FYI, the ondisk location for the MD superblock really depends on the
version (of the MD superblock) that the user elects to use.
v0.90 puts the MD superblock at the end of the disk (v1.0 puts it at
the same place).
v1.1 is at the start of the disk, v1.2 is 4K from the start of the disk.
Mike
_______________________________________________
Tux3 mailing list
Tux3 at tux3.org
http://mailman.tux3.org/cgi-bin/mailman/listinfo/tux3
More information about the Tux3
mailing list