Objective
To perform online reconfiguration of hardware RAID in Linux system.
Prologue
I have an IBM x3650 M2 with 6 physical hard disks (slot 0-5, 146GB each) and all of the hard disks have been configured as RAID 1 (slot 0 & 1 as 1 set of RAID, slot 2 & 3 as 1 set of RAID 1, slot 4 & 5 as 1 set of RAID 1). So, these hard disks are detected as 3 virtual disks (145.9 GB each) in my Linux system (/dev/sda, /dev/sdb & /dev/sdc).
Somehow, the System Architect asked me to configure RAID 10 on physical disks located in slot 2-5. So, we’ll be expecting to see 2 virtual disks (146GB + 292GB) in the OS. I have 2 choices; either do it in BIOS or using MegaRAID Storage Manager (MSM). Of course, I chose MSM because I can do it online with no interruption at OS level.
Material
Operating System: Red Hat Enterprise Linux 5.4 (don’t ask why I’m not using v5.5)
Hardware: IBM x3650 M2
RAID Card: IBM SystemX MegaRAID SAS 8808E (info taken from lspci -v)
MSM version: MegaRAID_Storage_Manager-8.00-05
Modus Operandi
- This is how my initial disk drives looks like in Linux,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [root@sgbwaprec02 ~]# fdisk -l Disk /dev/sda: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 17750 142472452+ 8e Linux LVM Disk /dev/sdb: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sdb1 * 1 3916 31455238+ 8e Linux LVM Disk /dev/sdc: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sdc1 * 1 17750 142576843+ 8e Linux LVM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- Then, I have to delete the last 2 virtual drives (virtual drive located in Drive Group 1 & Drive Group 2). Just right click on the Virtual Drive(s), then select to delete.
Before that, I’ve to ensure all partition in OS have been removed as well. Otherwise, we’ll see this error message,

So, delete all of existing partitions.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [root@sgbwaprec02 ~]# fdisk -l Disk /dev/sda: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 17750 142472452+ 8e Linux LVM Disk /dev/sdb: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System Disk /dev/sdc: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- We’ll see 4 unconfigured drives,

- Now, it’s time to create RAID10! Go to ‘Dashboard’ of MSM,

Click on ‘Create virtual drive’. - We’ll get this prompt,

Choose ‘Advanced’. - We’ll receive this menu-driven process,

On ‘RAID level’ option, select RAID 10. Then, add first 2 hard drives into Span 0 & next 2 hard drives into Span 1. After that, click on ‘Create drive group’. - Virtual drive is now created,

Click on ‘Next’, we’re almost done! - MSM will ask you to verify for the very last time,

Of course, click ‘Finish’. What are you waiting for, hehehe. - Tadaaaa, it’s done!
Verify the new configuration at OS level,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ [root@sgbwaprec02 ~]# fdisk -l Disk /dev/sda: 145.9 GB, 145999527936 bytes 255 heads, 63 sectors/track, 17750 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sda1 * 1 13 104391 83 Linux /dev/sda2 14 17750 142472452+ 8e Linux LVM Disk /dev/sdb: 291.9 GB, 291999055872 bytes 255 heads, 63 sectors/track, 35500 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
It looks good, isn’t it?
- If you’re using LSI MegaRAID card, you can perform online RAID reconfiguration by using MegaRAID Storage Manager. Yes, there’s no downtime or interruption on the operating system.
- I don’t have to rescan the hard disk in order to update the disk information after the RAID configuration (I thought I have to rescan SCSI bus)
You’ll get new window as below,

We’ll notice Drive Group0 of RAID10 is created. Now, click on ‘Create Virtual Drive’.
Conclusion/Observation


Post a Comment