From Linux Raid Wiki
Revision as of 08:44, 18 July 2007 by DavidGreaves (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Firstly it is worth noting that autodetect, whilst useful in simple situations, can cause real difficulties in more complex environments. It is now deprecated and although it is unlikely to go away entirely anytime soon, it should not really be used for new installations. See the RAID Boot page for more details of the suggested approach.

Any md arrays with partition type 0xfd using a 0.9 superblock should be auto-assembled by a standard kernel with the md driver builtin (ie not a module).

How it works

When a kernel with md support builtin boots, md notices any partitions of type 0xfd (raid autodetect) and automatically tries to assemble them into an array. (cfdisk and friends can help you determine the partition types.) md only considers components with the old (but still default in mdadm 2.5.2) version 0.9 superblocks. This can be checked using mdadm --examine /dev/<component>

The auto-detect and auto-assembly activity happens before the kernel tries to mount the root partition which can make having root on raid very easy.

The newer superblocks supporting named devices etc will not auto-assemble.

So an autodetect checklist:

  • are the partitions 0xfd ?
  • is the kernel standard?
  • is the md device builtin and not a module?
  • are the superblocks version 0.9?

Note that the boot-loader must be able to read the kernel image and AFAIK the only RAID type supported by a bootloader is RAID 1 on grub. This is nothing to do with auto-assembly.

Personal tools