Redhat/fedora The raid type in Linux

Source: Internet
Author: User
Keywords Linux redhat fedora
Tags aliyun array configure control data data processing different disk

The primary purpose of using redundant array of independent disks (RAID) is to improve the disk http://www.aliyun.com/zixun/aggregation/14345.html "> data processing capability and to provide redundancy of information."

RAID can be set up either through the operating system (software RAID) or through a dedicated RAID control card without setting up the operating system (hardware RAID). This chapter will explain how to configure a software RAID structure under Redhat/fedora Linux.

Whether it's hardware or software, redundant array raid can be configured with many different criteria, let's look at some of the most popular configurations

Linear raid

In linear raid, the RAID controller treats the RAID set (set) as a disk chain. After the current disk space is filled, the data sequence is written to the next disk in the disk chain. Linear RAID is designed to accommodate oversized file systems across disks without data redundancy. A drive failure will damage your data.

Fedora Linux does not support this mode of RAID.

RAID 0

Under RAID 0, the RAID controller attempts to write the data evenly to all disks in the RAID set (set).

Treat the disk as a plate and treat the data as a cake. Let's say you have four cakes-chocolate, vanilla, cherry, strawberry-and four dishes. The RAID 0 initial operation is to cut the cake into pieces and place the slices on each plate. The RAID 0 Drive lets the operating system feel the cake is complete and is placed on a large plate. For example, 4 9GB hard drives, configured as RAID 0 sets, the operating system treats them as a 36GB hard drive

Similar to linear raid, RAID 0 is designed to accommodate oversized file systems across disks without data redundancy. The advantage of RAID 0 is the speed of data access. A file is split on four disks and can be read at four times times the read speed of one disk. Remember that RAID 0 is often called a stripe set

RAID 0 allows disk sizes to be different. When raid uses the smallest stripe space on the disk, it continues to use the free space of the remaining disk as a stripe set. When this happens, the access speed of this part of the data slows down because the number of RAID drives is reduced. Therefore, RAID 0 is best to use a disk of the same capacity.

Fedora Linux supports RAID 0, figure 26.1 illustrates the data allocation process for RAID 0

RAID 1

In a RAID 1 mode, the data is copied and placed on another disk. This raid mode is often referred to as disk mirroring. Imagine that you will tell a similar story to two people, so that if one of them forgets the plot of the story, you can let the other one come to you.

When one of the disks in the RAID 1 set is broken, the remaining disk will still work. When a bad disk is replaced, the data can be automatically copied from the remaining good disk to the new disk. In the event of any primary RAID disk failure, RAID 1 can also automatically replicate data to a hot standby disk.

RAID 1 provides data redundancy but does not have the advantage of RAID 0 speed. One disadvantage of software RAID 1 is that the server has to write data two times to write to each mirrored disk. This takes up the data bus and CPU resources. Under Hardware RAID 1, the server CPU simply passes the data to the RAID disk controller, and the rest of the work is done by the disk controller. This enables RAID 1 o'clock to be prioritized for disk controllers

One limitation of RAID 1 is that the total RAID set size is equal to the disk with the smallest disk concentration capacity. This is different from RAID 0, which is wasted on the remaining portion of the larger disk.

Fedora Linux supports RAID 1. Figure shows the data distribution process in RAID 1 mode

How RAID 0 and RAID 1 work

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.