Showing posts with label Azure Configure Software RAID on Linux. Show all posts
Showing posts with label Azure Configure Software RAID on Linux. Show all posts

Monday, 21 July 2014

Azure Configure Software RAID on Linux

   
Following are the steps to create RAID 5 Array on Ubuntu 12.04 LTS machine.

          è  Attach 5 hard disks each one with 500 GB.

 è Partition all hard disks.

 è Install the mdadm using the below command.
             apt-get install mdadm

 è Create the RAID 5 array using below command.
             mdadm --create /dev/md127 --level=5 --raid-devices=5 /dev/sdc1 /dev/sdd1 /dev/sde1 /dev/sdf1                     /dev/sdg1

 è Partition the RAID 5 array /dev/md127 and we get the /dev/md127p1 partition.

 è Format using the ext4 file system.
             mkfs –t ext4 /dev/md127p1

 è Add the configuration to mdadm.conf
             mdadm --detail --scan >> /etc/mdadm/mdadm.conf
             Edit the mdadm.conf file to contain only the device name and UUID like below.
             ARRAY /dev/md127 UUID=*********

 è You need to update initramfs so it contains your mdadm.conf settings during boot.
             sudo update-initramfs –u

 è Get the UUID of RAID 5 partition to add entry in fstab. Execute the below command to get UUID.
             sudo /sbin/blkid
             Copy the UUID of /dev/md127p1

 è Add the entry in fstab like below.
             UUID=****  /mountpoint      ext4       defaults, nobootwait     0              2

 è Change the bootdegraded value to true in below file.
             /etc/initramfs-tools/conf.d/mdadm

 è Add the bootdegraded=true property in GRUB_CMDLINE_LINUX_DEFAULT like below in               /etc/default/grub file.
            GRUB_CMDLINE_LINUX_DEFAULT="console=tty1 console=ttyS0 earlyprintk=ttyS0                           rootdelay=300 bootdegraded=true"

 è After updating the above file execute the below command.
            sudo update-grub

 è Check the mount configuration using below command.
           mount -a