With the release of kernel 2.6.17, there’s new functioanlity to add a device (dpartition) to a RAID 5 array and make this new device part of the actual array rather than a spare.
My HOME directory is mounted on a 3×70gb SCSI RAID5 array. so I tried adding a further drive.
Although with the release of mdadm > 2.4 the only real critical part of the process is safer (it backs up some live data that is being copied), I didn;t fancy risking growing a mounted array. So I did plenty of backups, then switched to single user run level.
Basically the step includes adding a disc to the array as a spare, then growing the array onto this device.
mdadm --add /dev/md1 /dev/sdf1
mdadm --grow /dev/md1 --raid-devices=4
This then took about 3 hours to reshape the array. The filesystem the needs to be expanded to fill up the new space.
fsck.ext3 /dev/md1
resize2fs /dev/md1
I then remounted the drive and wahey. Lots extra space….! Cool or what