OpenBSD 5.1 brings new cool features like this one:
"boot(8/amd64) is teached how to access softraid(4)
volumes, which allows a kernel to be loaded from a softraid RAID 1
volume. Furthermore it is sufficient to only boot from a disk that is a
member of a bootable softraid volume, as this case will be detected and
the boot will automatically be redirected to sr[0-9]a:/bsd."
This mean that the bootloader can boot directly from a softraid(4) partition: No more "standard" partitions needed with kernel copied on them on both hard drive!
Here is how to proceed:
During your CD-ROM boot, check that you have a minimum of 2 hard drives detected:
Continue the boot process and select to launch a shell:
Display the names of the disks detected by OpenBSD:
On this example (Virtualbox VM), we've got 2 SATA hard-drives: wd0 and wd1 (cd0 is the CD-ROM and rd0 is the RAM drive created by the kernel).
By default OpenBSD create only one /dev for the first hard drive, we need to create a second and initialize a MBR to them:
Now, we need to create a BSD label named "raid" to both disks.
We will create a BSD label for the first drive, and dump/restore the label table to the second drive:
Now we can create a softraid(4) volume using the two "a" partitions :
This will create a new drive: sd0 in this example.
Return back to the OpenBSD installer (Ctrl+D), and select this new softraid disk for the destination root disk:
Once installed, simply reboot and enjoy: