[GRLUG] Software Raid Setup (Disk Druid)

Ben DeMott ben.demott at gmail.com
Thu Jun 25 19:33:49 EDT 2009


Hello Everyone!
I recently had to provision a server or two, and everytime I do I second
guess myself on Software Raid configurations (and DRBD) for that matter.
So this time around I wrote very good and detailed instructions (and took
pictures) to get a Raid 1 Mirror for a complete noob.
(no pictures in this email)

Thought I would share if anyone is trying to do it in the near future on a
home desktop perhaps.

I was kind of shocked I couldn't find half way decent instructions like this
on the internet, instead I sort of did it by memory which was a bit painful
at moments and made me second guess myself at least a few times.

Hope this is helpful!

Unix/Linux Disk Naming Conventions
=========================================================
hda = Physical Volume Label
hda1 = First Partition of Physical Volume hda

hdb = Second Physical Volume
hdb1 = First Partition of Physical Volume hdb

sda = Serial or SCSI Physical Volume
sda1 = First Partition of Physical Volume sda
sda2 = Second Partition of Physical Volume sda


Software Raid Configuration on Fedora Core 11 / Red Hat (Disk Druid)
==========================================================
This assumes your first Hard disk is "sda", your second hard disk, is "sdb"
and you are trying to setup a Raid Mirror (Raid 1), with no Hot Standby
Drives.

1.) Click New (to setup a boot partition)
    # Boot has to exist within a physical volume, because during system boot
grub doesn't know about our raid array yet, so it needs something 'physical'
to actually access.
    Under Mount Point -> set to "/boot"
    Under File System Type -> Select "ext3"
    Under 'allowable drives' select sda (or your first hard drive)
    Under 'additional size options' -> select 'Fixed Size', and set the size
to 200mb
    click OK

2.) Click New
    Under file system type -> Select "Software Raid"
    Under 'allowable drives' select sda (or your first hard drive)
    Under 'additional size options' -> select 'fill to maximum allowable
size'
    click OK

3.) Repeat the same step as step #2 for your second hard drive (sdb)

Note: If you want additional drives to be apart of this raid array repeat
these steps for each physical volume (physical hard disk)

4.) From the Main Menu
    Under sda-> you should see sda1 | /boot         | ext3          | 196
(approx)         |
    Under sda-> you should see sda1 |               | software RAID | hard
disk total size |
    Under sdb-> you should see sda1 |               | software RAID | hard
disk total size |

    -If you added additional Raid Volumes you should see something similar
to the two raid volumes above under their respective Physical Volume Labels.

5.) Click the RAID button.
    Select "Create a Raid Device"
    Click "Ok"
        Under "File System Type" -> select "Physical Volume (LVM)"
        Under "Raid Device" -> select your label the default of "md0" is
fine, make sure to remember this for the next step.
        Select Raid Level (Raid 1) - which is a raid mirror (you are welcome
to use any other RAID type you prefer, the steps are the same)
        Under "Raid Members" -> check both hard drives sda2, sdb1. (your
first raid partition, and your second raid partition)
        (If you would like to encrypt your hard drives and require a
password during boot check "encrypt")
        Click Ok (returns to root menu)

6.) Click "LVM" (VERY IMPORTANT! Make sure you don't click NEW)
    Enter a volume group name (leaving default is fine) - just remember what
the name is.
    Under "Physical Extent" -> (Leave this alone, 32mb is fine by default)
    Under "Physical Volumes" -> to Use -> Make sure that md0 is checked (or
the raid device label you selected in the previous step)
    Under "Logical Volumes" -> click "Add"
        Under "File System Type" -> enter "/swap"
        Under "Logical Volume Name" -> set the field to something logical
like "VolSwap".
        Under "Size (MB)" -> set to your machines physical memory size x 2.
        Click Ok

    Click "Add" Again
        Under "Mount Point" enter "/"
        Under "File System Type" enter "ext3" (or your desired partition
type)
        Under "logical Volume Name" -> set the field to something logical
like "VolRoot".
        Under "Size (MB)" -> leave at default size (Should be maximum volume
size).
        Click Ok to exit this sub menu

    Click Ok Again to exit the LVM Menu

7.) You are now done
    Click "Next" at the main menu to Finish.
    When prompted click "Write Changes to Disk" or "Go Back" if you feel you
missed something.

If you see any errors, you did something wrong - please consult specific
technical documentation, or try these steps again.

You should see Fedora formatting /File System... with a progress bar,
Software Raid is being Setup.

Another feature of Software raid is it can have Hot Spares / Standby drives,
although we do not discuss this here.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://shinobu.grlug.org/pipermail/grlug/attachments/20090625/63065e48/attachment-0001.htm 


More information about the grlug mailing list