The difference between disk array raid and hardware RAID and software raid on the Linux learning path

Source: Internet
Author: User

We know that the capacity of a single disk storage data is limited, in order to increase the capacity of the disk, we can combine a number of smaller disks together to form a larger disk device, which is a raid (stand-alone disk array), RAID can not only improve the storage capacity of data, but also improve the data protection function, Different levels of RAID, the functionality provided varies.

Raid common levels are RAID0,RAID1,RAID5,RAID10,RAID01,RAID5,RAID50

The following sections describe how these levels work.

RAID0: First divide the disk into equal chunks (CHUNK), then divide the stored data into blocks of CHUNK size and place them on each disk in turn. Stored evenly on each disk in the array in the form of a stripe.

Storage mode:

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/39/53/wKiom1O4tHSzK2kTAADdaYl5Sbc482.jpg "title=" r0.png "alt=" Wkiom1o4thszk2ktaaddayl5sbc482.jpg "/>

The size of the so-called bands is obtained by dividing the size of the chunk by the size of the block. The default chunk is 64k.

The RAID0 has the following characteristics:

1. At least 2 disks can be combined into raid, preferably the same disk

2, the data is stored evenly on each disk, so read and write performance improvement

3, so that the stored data is not redundant, so any one of the disk corruption, the data is bad.

4, the utilization of the disk is 100%


RAID1: Because the RAID0 does not provide a redundancy mechanism for the data, the data cannot be restored when one of the disks is damaged. While the storage mechanism of RAID1 is different from raid, the RAID1 is to store one copy of the data on two disks in the same way by mirroring redundancy. This way, when one of the disks is damaged, you can also work from another disk.

stored in the following ways:

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/39/53/wKioL1O4uNTSo_oeAACFMZ6XG1k404.jpg "title=" r1.png "alt=" Wkiol1o4untso_oeaacfmz6xg1k404.jpg "/>

RAID1 will have the following characteristics:

1. At least 2 disks are combined into RAID1, preferably with the same disk

2, because the data is saved on each disk, so the write performance of the disk degraded, read performance improved

3, this storage mode has redundancy

4, the space utilization of the disk is 50%



As you know from above, RAID0 is not redundant, and when a disk is damaged, all data is corrupted. While RAID1 is redundant, the utilization of the disk decreases and the write performance of the disk decreases. Is it possible to combine RAID0 and RAID1 with the characteristics of RAID0 and RAID1?

The whole column that combines RAID0 and RAID1 has 2 RAID10 and RAID01

RAID10: The disk is first combined into RAID1, then RAID0 group synthesis RAID0.

stored in the following ways:

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/39/53/wKioL1O4v_DDkXPAAAECB5Gonxk164.jpg "title=" R10.png "alt=" Wkiol1o4v_ddkxpaaaecb5gonxk164.jpg "/>

The RAID10 has the following characteristics:

1, at least 4 disks can be composed. , because RAID1 and RAID0 have at least two disks to make up.

2, because of the reason of RAID1, so performance decreased, read performance improved

3, because of the reason of RAID1, so this combination has redundancy

4, disk utilization is 50%


RAID01: The disks are now combined into RAID0, and then the RAID0 group is synthesized RAID1

stored in the following ways:

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/39/53/wKiom1O4wzbDCLDjAAECA9D5Iuc142.jpg "title=" R01.png "alt=" Wkiom1o4wzbdcldjaaeca9d5iuc142.jpg "/>


RAID5: will require at least three disks to be combined into RAID5, one of which is used to store the same-bit check code and is stored in a round-robin manner on each disk. The data is stored evenly and sequentially on the other disk.

When one of the disks is damaged, you can use the same-bit check code to recover data from another disk.

stored in the following ways:

650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M01/39/54/wKiom1O4yiaQoBduAAD5EiNz2X8771.jpg "title=" r5.png "alt=" Wkiom1o4yiaqobduaad5einz2x8771.jpg "/>

The RAID5 has the following characteristics:

1, because one of the disks to store the same bit check code, so at least three disks required to form a RADI5

2, because of the existence of the same bit check code, so the write performance of the disk degraded, read performance improvement

3, because can use the same bit check code to recover the data of the disk, therefore has the redundancy

4. Disk space utilization is (n-1)/n


RAID50: Combines the disks first into RAID5, and then the combined RAID5 Group is synthesized RAID0

650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/39/54/wKiom1O4zeWC7bOvAAFAg9dhsA0435.jpg "title=" R50.png "alt=" Wkiom1o4zewc7bovaafag9dhsa0435.jpg "/>

RAID50 will have the following characteristics:

1, because of the reason of RAID5, so need at least 6 disks to combine into RAID50

2, because there is the same bit check code, so disk write performance degradation, read performance improvement

3, with redundancy function

4. Disk utilization is (n-2)/n


In addition, there is a disk combination mechanism JOBD technology

JBOD: is to stack multiple disks into a large logical disk, and then use the second disk when the first disk is out of capacity.

Thus JBOD has the following characteristics:

1. Requires at least 2 disks to be combined into JBOD

2. Data is stored sequentially from the first disk, so read and write performance is not improved

3, no redundancy mechanism, when one of the disks is damaged, the data will be corrupted

4, disk utilization is 100%



The above mainly describes several common levels of RAID principles, RAID can be combined by hardware and software, then hardware RAID and software RAID what is the difference?




This article from the "Linux Learning Path" blog, declined reprint!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.