[Nottingham] Large disks and storage (md raid)
Martin
martin at ml1.co.uk
Thu Sep 10 21:08:36 UTC 2009
Martin wrote:
>> ... md raid1/raid10f2/raid5 :)
>
> Which comes to another question... :-)
>
> From "man 8 mdadm":
>
> "Use the new version-1 format superblock. This has few restrictions. The
> different subversion store the superblock at different locations on the
> device, either at the end (for 1.0), at the start (for 1.1) or 4K from
> the start (for 1.2)."
>
>
> So...
>
> Why would you want the raid superblock to be 4k from the start?
>
> And for the sake of ssd/stripe alignment, how big is the superblock?
>
> Why not simply have the superblock at the end (v1.0)?
>
> Are the later versions actually later versions or just variations for
> the sake of moving the superblock around?
The "what" is nicely explained in "man 4 md" (appended below). That
suggests that for a 1.1 md array, you'll always have a misalignment!
That still leaves all the whys... And why not just set to always use a
1.0 superblock? Why the later versions?
Cheers,
Martin
From "man 4 md":
... version 0.90 - has a superblock that is 4K long and is written into
a 64K aligned block that starts at least 64K and less than 128K from the
end of the device (i.e. to get the address of the superblock round the
size of the device down to a multiple of 64K and then subtract 64K). The
available size of each device is the amount of space before the super
block, so between 64K and 128K is lost when a device in incorporated
into an MD array. This superblock stores multi-byte fields in a
processor-dependant manner, so arrays cannot easily be moved between
computers with different processors.
The new format - known as version 1 - has a superblock that is normally
1K long, but can be longer. It is normally stored between 8K and 12K
from the end of the device, on a 4K boundary, though variations can be
stored at the start of the device (version 1.1) or 4K from the start of
the device (version 1.2). This superblock format stores multibyte data
in a processor-independent format and has supports up to hundreds of
component devices (version 0.90 only supports 28).
The superblock contains, among other things:
LEVEL
The manner in which the devices are arranged into the array (linear,
raid0, raid1, raid4, raid5, raid10, multipath).
UUID
a 128 bit Universally Unique Identifier that identifies the array that
this device is part of.
--
----------------
Martin Lomas
martin at ml1.co.uk
----------------
More information about the Nottingham
mailing list