fdisk and disklabel

Assuming the disk device is sd1

Add a blank partition list:

fdisk -f -a -0 sd1

Create a RAID label:

disklabel -i -I /dev/rsd1d

Initial Setup

Setup first time:

raidctl -v -i /dev/raid5 -C /etc/raid5.conf

Display status:

raidctl -m /dev/raid5
raidctl -s /dev/raid5
raidctl -S /dev/raid5

Check if parity is up to date:

raidctl -p /dev/raid5

Initialize the parity if it is known to not be up-to-date (used when after a system crash):

raidctl -P /dev/raid5

Configuration File

Each configuration file has four required sections, and two optional ones. They all begin with START and then the section name.

First is the array section, which defines the number of rows, columns, and spare disks.

A RAID5 array of 1 row, 4 disks and 0 spare disks

START array
1 4 0

The disks section specifies the actual devices in the RAID array:

START disks

The layout section defines sectors per stripe unit, stripe units per parity unit, stripe units per reconstruction unit, and the parity configuration to use.

This example is from the man page, for RAID5:

START layout
# sectPerSU SUsPerParityUnit SUsPerReconUnit RAID_level
32 1 1 5

Final required section is queue. Again, using the man page as a reference:

START queue
fifo 100