On Friday June 8, [EMAIL PROTECTED] wrote:
> Ooooohhh...does this mean I can move ALL of my disks and still start the
> array?  I've had a couple times now when I removed one disk and ALL the
> others bumped down a notch so raid wouldn't autostart.  It would find the
> first disk but the others would all be out-of-place.

Yes, that is the plan.

> 
> Also....can mdctl be used to show the current raid devices (i.e.
> automatically create a raidtab entry???) -- this would be as a sanity check
> before you try a mkraid on things...

Well, mdctl can already show information about current raid devices.
   mdctl --detail /dev/md0
will give detail about the array at /dev/md0, if there is one.
   mdctl --examine /dev/sda
will read and decode an RAID superblock what it finds on /dev/sda.
It would not be too hard to convert the output of these into a raidtab
file if you wanted to.

But mdctl will not use a raidtab file.

I haven't finalised the organisation of the config file that it can
use but it will contain essentially two things:

1/ A mapping from UUID to md-device so that when it find devices with
   RAID superblocks, it knows which device you want them to be
   associated with.
2/ A list of devices that it is allowed to scan for RAID superblocks.

The idea is that when you create a raid array, you do it with a
command, not a config file:
   
   mdctl --create /dev/md0 --level=5 --chunk=32
   --layout=left-asymetric --raid-disks=5 /dev/sda /dev/sdb /dev/sdc
   /dev/sdd /dev/sde

And then you put the uuid into the config file:

    mdctl --detail /dev/md0 | awk '$1 ~ /UUID/ { printf "ARRAY: dev=/dev/md0 
uuid=%s\n", $3 }' >> /etc/md.conf
    echo "DEVICES: /dev/sd?" >> /etc/md.conf
or something.. possibly just an extra flag to mdctl.

Finally, at boot time, to start arrays, you say:

    mdctl --assemble --scan

which scans the default mdconf file for devices, and finds any with
known UUIDs, and assembles them.

NeilBrown
-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to [EMAIL PROTECTED]

Reply via email to