NOTE: Another guide shows how to install Debian using SATA RAID (aka. fake/soft/software/firmware/driver-based/BIOS RAID adn HostRAID) provided by your SATA disk controller (not to confuse with Linux SATA RAID facilitated fully by kernel drivers). The guide applies to Lenny, Squezee and may be later releases and uses GRUB2.

It used to be hard to set up Software Raid (often called SATA RAID) on Debian, but the latest installers have a working menu for that. It's highly recommended over setting up RAID manually!!!

If you're struggling with lack of support for your SATA RAID controller, check out the ?ServerHardware page for some help on that.


The RAID configuration starts with the Partition table menu

I often choose "Manually edit partition table", but that's just my choice, and what I've described here.

Then go to each disk. If they're brand new, use arrows down to the free space and click enter. (If you want to start over, click enter on each partition and choose delete the partition. Do this for each partition you want to remove.)

Choose your partition scheme.

When you've created your partitions, go back into each partition, and go to "Use as" and swap file system to "physical volume for RAID". Then you're "Done setting up the partition".

Go to "Configure software RAID".

Choose Yes, to the question to "write the changes to the storage devices and configure RAID?"

Create MD device

Choose your raid type (two disks mirrored is RAID1).

It kicks back an error - "No RAID partitions available". Just choose Continue. Next image is the "Multidisk (MD) and software RAID configuration menu again". Just click on Finish.

By now the raid devices are there.

Go in to each of the RAID partitions and set your file system, and any bootable flags (Mount point) etc that weren't set automatically.

Finally click on "Finish partitioning and write changes to disk".

If you haven't missed anything, it'll come up with a warning and confirmation screen, with a summary of the changes you are about to make.

Click Yes.


I thought that was it, but when I removed the first disk, it wouldn't boot (grub error 15). I have grub installed in MBR and ReiserFS file system. And this is what fixed it for me:

Input these commands verbatim:

grub --device-map=/boot/grub/device.map

(at this point you get a different prompt, with grub>)

root (hd0,0)

setup (hd0)

root (hd1,0)

setup (hd1)

quit

After I did this, shutdown and nixed the first drive, then the second drive booted.


Unfortunately I found no documentation of this when I set up RAID, so hopefully this will help others.