Re: SATA controllers and kernel port assignment in Linux





On Mon, 4 Dec 2006, John-Paul Stewart wrote:

darrins@xxxxxxxxx wrote:

Right now I have one drive on the motherboard (/dev/sda) and two drives
on the Card (/dev/sdb and /dev/sdc). The two drives on the card are
mirrored in a software raid-1 configuration. If in the future I add
another drive to the second port on the motherboard, it will be
assigned as /dev/sdb and then my raid drives will jump to /dev/sdc and
/dev/sdd. I can rebuild the raid at that point, but that always makes
me nervous

There shouldn't be any need to re-build the array. Assuming you're talking about a modern soft-raid with partition type 0xfd (RAID autodetect), the kernel doesn't care about the /dev/sd* names. What matters is the GUID that's written into the RAID superblocks of those devices. The kernel will create the RAID from the matching pair of GUIDs regardless of their /dev names.

Is there an easy, safe way to migrate from the old raidtools style RAID to the new auto-detect mdadm type arrays?

I suppose that I could manually fail one device in my old (RAID1) array and then define a partiton on this drive as a new mdadm-style array (with a missing drive), copy the data over, then re-partition and add the other drive and re-build, but is there an easier way?
.