This is an old revision of the document!


How to install Owl on software RAID

Owl's installer program - settle - is not able to create software RAID devices yet, however it lets an advanced user install onto software RAID devices created via the command-line. Here's how to do it.

In the following examples, we'll assume the typical use case for software RAID - installing onto two mirrored hard drives (RAID-1).

Partition the hard drives

You may partition the first one of your hard drives via settle or by running fdisk manually:

fdisk /dev/sda

Create partitions, then quit fdisk saving your changes. Copy the partition table to the second hard drive:

sfdisk -d /dev/sda | sfdisk /dev/sdb

You may use partition type fd (Linux software RAID autodetect) or you may use types such as 82 and 83 (Linux swap and filesystem, respectively) or even type da (data). If you choose not to use the autodetect, which has its pros and cons, you'll need to have the installed system explicitly assemble the software RAID arrays before it needs them - e.g., this may be achieved with the md= parameter to the kernel (an example is given below).

Create the software RAID arrays

mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1

…and so on for /dev/md1 on /dev/sda2 and /dev/sdb2, etc.

The RAID arrays are available for use right away, even though they're being resync'ed in the background (the status of this process may be seen with cat /proc/mdstat).

Install the system

Run settle and proceed to install the system mostly as usual. Choose the “Use uNlisted partition for root”, “Mount uNlisted partition”, and/or “Use uNlisted swap partition” menu items as appropriate. These will prompt you to enter a device name - you'll need to enter /dev/md1 and so on as appropriate.

If you put your boot filesystem 1) on software RAID (which you should probably do) or/and if you chose not to use the autodetect, then there's an extra step to perform. After installing the bootloader (still via settle), don't reboot the system yet. Instead, exit from settle, edit /owl/etc/lilo.conf, and re-install LILO:

chroot /owl
vi /etc/lilo.conf
lilo
exit # from chroot

You need to add the following line to lilo.conf:

raid-extra-boot=mbr

Additionally, if you chose not to use the software RAID autodetect partition type, you need to add something like:

append="md=0,/dev/sda1,/dev/sdb1 md=1,/dev/sda2,/dev/sdb2 md=2,/dev/sda3,/dev/sdb3 md=3,/dev/sda4,/dev/sdb4"

(Of course, you need to make both of these edits during the vi /etc/lilo.conf step above, before running lilo.)

If lilo says:

Fatal: bios device code 0x82 is being used by two disks

Then you need to add following lines to /owl/etc/lilo.conf (these lines specifies BIOS codes for the devices):

device=/dev/sda
    bios=0x80
device=/dev/sdb
    bios=0x81

After lilo operated success, unmount the filesystems and reboot. You may do so by running settle again and using its “Reboot to the newly-installed system” menu item, which includes the necessary logic.

Back to Openwall GNU/*/Linux user community resources.

1) With Owl, there's currently no need to separate out /boot onto its own filesystem, so normally your boot filesystem will also be your root filesystem
Owl/software-raid.1411485507.txt · Last modified: 2014/09/23 17:18 by grumbler_eburg
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate to DokuWiki Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki Powered by OpenVZ Powered by Openwall GNU/*/Linux