Sebastian Mogilowskis Blog

Just another blog about administration, linux and other stuff

Language: German English

Linux Software RAID 5 on Debian Lenny or Ubuntu

This is an update Post for my old Howto http://www.mogilowski.net/lang/de-de/2008/05/09/linux-software-raid-5-unter-debian-etch for Debian Lenny and Ubuntu.

In this configuration i created a raid 5 with the drives sda, sdb, sdc and sdc. (Change it to your configuration if you need it.)

1. Installation

aptitude install mdadm

2. Create Raid

Insert this line in the mdadm config file “/etc/mdadm/mdadm.conf”:

ARRAY /dev/md0 level=raid5 devices=/dev/sda,/dev/sdb,/dev/sdc,/dev/sdd

Now create the raid:

mdadm --create /dev/md0 --verbose --level=raid5 --raid-devices=4 /dev/sda /dev/sdb /dev/sdc /dev/sdd

The following command shows you some details of your new raid:

mdadm --detail /dev/md0

Look at:

Rebuild Status : 2% complete

This shows you, that the raid is build in background, but you can already use it if you like.

Active Devices : 4
Working Devices : 4
Failed Devices : 0
Spare Devices : 0

This shows you that all 4 disks are working and none of them is missing.

3. Format

Now format your new raid device. With ext3 for example:

mke2fs -j /dev/md0

Mount the new partition:

(mkdir /media/raid)
mount /dev/md0 /media/raid

or add it directly to /etc/fstab”:

/dev/md0 /media/raid ext3 suid,dev,exec  0  0

, , , ,

3 Responses to “Linux Software RAID 5 on Debian Lenny or Ubuntu”

Leave a Reply

Your email address will not be published. Required fields are marked *

*


*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

eMail-Benachrichtigung bei weiteren Kommentaren.
Auch möglich: Abo ohne Kommentar.