Operating System - Linux
1828667 Members
1639 Online
109984 Solutions
New Discussion

RAID 1 and Linux Disk Partition

 
SOLVED
Go to solution
scott_417
Frequent Advisor

RAID 1 and Linux Disk Partition

In a case that DL360 has two mirroring disks, Disk 1 and Disk 2 (RAID 1 implemented). The Operating System is Linux.

If I parse the Disk 1 into:

hda1 for OS and
hda2 for data file

what should I do about the Disk2? --I mean, do I need to parse the Disk 2 into corresponding hdb1 and hdb2? Or the RAID system will automatically parse Disk 2 and make it mirror Disk 1?


Thanks to help.

Scott
4 REPLIES 4
Patrick Terlisten
Honored Contributor
Solution

Re: RAID 1 and Linux Disk Partition

Hello Scott,

do you have a hardware-raid (Smart-Array) or software-raid (MD Device Driver)?

If you use a hardware-raid the two disks build one RAID-1 array. If you create partitions on that RAID-1, both partitions will be mirrored. If you use a software-raid, you got a MD-Device (/dev/md0). In this case, you need to create two partitions on that device.

Regards,
Patrick
Best regards,
Patrick
scott_417
Frequent Advisor

Re: RAID 1 and Linux Disk Partition

Thanks for the response.

Does this mean, though there are two disks in RAID 1, the Linux sees or treated them as one device--correct? If so, I just take them as if I only have one hard drive and do the partition such as hda1 (for OS), hda2 (for log files), etc. --right?


Thanks to help.

Scott
Ivan Ferreira
Honored Contributor

Re: RAID 1 and Linux Disk Partition

Scott, you should post your question in just one cathegory. You will get answers anyway, but the answers will be organized.

When you create a raid, the OS sees only one device. You don't need to worry about the disks, you only need to work when one disk fails.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Patrick Terlisten
Honored Contributor

Re: RAID 1 and Linux Disk Partition

Hello Scott,

if you have a hardware-raid (two disks connected to a Smart-Array controller and configured as RAID 1), you see only one (virtual) disk. On that disk you can create your partitions. Try the following command:

fdisk /dev/ida/c0d0

Regards,
Patrick
Best regards,
Patrick