Migrating To A Mirrored RAID Using GRUB

Summary: Migrating an existing single-drive installation of Linux, which uses GRUB for the bootloader, to a fully mirrored RAID-1.

This guide is based off of three documents, which I recommend you read prior to attempting the steps documented here. The primary resource is a a posting by Steve Cole (referring to this as the “failed disk” method) on the Linux-Sparc mailing list. I also referred to my own guide on setting up a mirrored root RAID, as well as a HOWTO by Steve Boley. For slightly different configurations from those outlined below, you may need to refer to Michael Martucci’s “GRUB + RAID howto” posted to the LinuxSA mailing list; for help with loading the RAID-1 module at boot time, refer to Roger Chrisman’s “SW RAID-1 and Swap partitions, etc.” post on the Balug-talk mailing list. You may also want to read the Software-RAID HOWTO, specifically the section called “Converting a non-RAID RedHat System to run on Software RAID”. For help compiling the kernel “the Debian way,” you may want to read Debian’s FAQ on Debian and the kernel.

This article assumes you are using GRUB as your bootloader, and that you have an existing, working, and bootable installation of Linux. This document should contain every command required to convert a single drive over to a fully mirrored RAID-1 system. During the process, you will have an opportunity to change the filesystem type (perhaps from Ext2 to XFS or ReiserFS); I will be migrating partitions from Ext2 to Ext3 and XFS.

My Linux distribution of choice is Debian, and this guide was written with this distribution in mind. However, aside from the initial software package installation and the compilation/installation of the kernel, the rest of the guide should be applicable to all Linux distributions.

Read more at www.doorbot.com


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s