CN102945191A - RAID5 (redundant array of independent disk 5) data transfer method - Google Patents
RAID5 (redundant array of independent disk 5) data transfer method Download PDFInfo
- Publication number
- CN102945191A CN102945191A CN2012104593257A CN201210459325A CN102945191A CN 102945191 A CN102945191 A CN 102945191A CN 2012104593257 A CN2012104593257 A CN 2012104593257A CN 201210459325 A CN201210459325 A CN 201210459325A CN 102945191 A CN102945191 A CN 102945191A
- Authority
- CN
- China
- Prior art keywords
- data
- sector
- raid5
- read
- write
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Abstract
The invention provides an RAID5 (redundant array of independent disk 5) data transfer method. The method has the realization processes that when errors occur because of little sector damage, effective data blocks are transferred onto a checking data block of the same belt, and the sector damage refers to the sector reading and writing reported errors or periodic hard disk scanning discovered medium or data errors. Compared with the prior art, the RAID5 data transfer method has the advantages that when effective data generates reading and writing errors, the effective data blocks are transferred onto the checking data blocks of the same belt, and the system reliability is greatly improved.
Description
Technical field
The present invention relates to field of computer technology, be specifically related to the method that a kind of RAID5 data shift.
Background technology
For the RAID system with redundancy check information, fault tolerance has become the most popular characteristic of disk array, for the function that adds strong fault tolerance and make system in the situation that disk failure data reconstruction rapidly, to keep the performance of system, general disc array system all can use the function of Hot Spare, so-called Hot Spare is when setting up disc array system, wherein a disk is appointed as back-up disk, this disk is in usual and inoperation, but when if a certain disk breaks down in the array, disk array namely replaces failed disk with the reserve disk, and automatically with the data reconstruction of failed disk on hot standby disk.Some disk arrays (such as RAID5) have only allowed a dish to lose efficacy, and when having second dish to lose efficacy, whole disk array had just lost efficacy.
Some disk array fall dish because a small amount of bad sector causes.Owing to the disk failure that a small amount of bad sector causes, greatly reduce the reliability of system.Nearly all hard disk all can have bad sector, and from damage type, bad sector can be divided into two classes: soft damage sector and physical damage sector.Cause soft damage sector often virus or some software, is not real bad sector, can repair by format again.Another kind is the bad sector that physical damage causes, data will can't be written in this sector forever.The bad sector that these two kinds of forms cause can shift to keep away by data and return.For RAID5, when same when surpassing 1 data block damage arranged, then can't repair; When the data block quantity of damaging is 1, then can repairs by checking algorithm, but be in degrading state this moment, no longer possesses redundancy scheme, there is again data block to damage, just can't repairs, so, when a bar damages with a blocks of data piece, the True Data piece is more important than checking data piece, if damage is the True Data piece, just through calculating this data block, then writing the checking data piece gets the position and gets on the line item of going forward side by side.If what damage is check block, then needn't calculate this piece, only record and get final product.Based on this, the method that now provides a kind of RAID5 data to shift.
Summary of the invention
Technical assignment of the present invention is in the deficiencies in the prior art, and a kind of method of RAID5 data transfer is provided.
Technical scheme of the present invention realizes in the following manner, the method that these a kind of RAID5 data shift, the implementation procedure of the method is: when generation is wrong because a small amount of sector corruption produces, the valid data piece is transferred on the checking data piece with band, and above-mentioned sector corruption refers to that the sector read-write reports an error or the periodic scan hard disk is found medium or error in data.
The process that described valid data piece shifts refers to: when a bar damages with a blocks of data piece, if what damage is the True Data piece, passes through and calculate this data block, then write the checking data piece and get the position and get on the line item of going forward side by side; If what damage is check block, then needn't calculate this piece, only record and get final product.
The described sector read-write process of reporting an error is:
1), checks at first whether read-write operation is the bad sector that has recorded;
2) if this sector record is bad sector, and be the checking data piece, then can ignore; If be non-checking data, read and write data on the verification sector of arriving, and judge whether to make mistakes;
3) if mistake appears in the read-write check sector, illustrate that then plural data block error appears in this band, can't repair, just declare that array lost efficacy, and allowed the user process; If mistake does not appear in the read-write check sector, directly return these data and get final product.
Described periodic scan hard disk only carries out in device free.
The beneficial effect that the present invention compared with prior art produces is:
The method that a kind of RAID5 data of the present invention shift is when valid data generation read-write error the time, and the valid data piece is transferred on the checking data piece with band, does not affect usability, has greatly improved system reliability, the probability of minimizing loss of data.
Description of drawings
Accompanying drawing 1 is sector corruption fault decision-making schematic diagram of the present invention.
Accompanying drawing 2 is that data of the present invention shift schematic diagram.
Accompanying drawing 3 is that sector record represents intention.
Accompanying drawing 4 is sector map cell schematics.
Accompanying drawing 5 is to read and write the analysis process figure that makes mistakes.
Embodiment
Below in conjunction with accompanying drawing the method that a kind of RAID5 data provided by the present invention shift is described in detail below.
The method that a kind of RAID5 data shift, the implementation procedure of the method is: when generation is wrong because a small amount of sector corruption produces, the valid data piece is transferred on the checking data piece with band, as shown in Figure 1, above-mentioned sector corruption refers to that the sector read-write reports an error or the periodic scan hard disk is found medium or error in data, i.e. bad sector fault decision-making then mainly contains two aspects:
1), reports an error by the sector read-write, as fault decision-making of data transfer.
2), the periodic scan hard disk finds medium or error in data, a fault decision-making of shifting as data.
When a bar damaged with a blocks of data piece, the True Data piece was more important than checking data piece, if what damage is the True Data piece, just through calculating this data block, then write the checking data piece and got the position and get on, and the line item of going forward side by side is such as Fig. 2.If what damage is check block, then needn't calculate this piece, only record and get final product.
For the record data transinformation, set up a sector record table, such as Fig. 3, each of form sector number that comprises original logic sector number and newly shift, this form can be put into disk metadata space, is put into internal memory in the time of use.In addition, what sectors also have a counting array to record each disk has shift.
For the disk size of 4TB, use 34 to get final product the presentation logic sector number, because the position of the checking data piece of a band is determined, so only the original data block location of damaging of record gets final product, disk size expansion after considering, and zone bit, with record of 64 bit representations.Wherein, first is zone bit, and whether represent had transfer, such as Fig. 4, record count to arrange.
When having the sector that read-write error occurs, record is the mistake which sector occurs, and increases the bad sector statistical counting of this dish.In the sector record form, fill out and wrong sector number, the position of data being write checking data occur; If what damage is the checking data piece, only carries out record at the sector record form, and do not carry out the transfer of data.
When the bad sector number of a certain dish is too much, just declare that this piece dish lost efficacy, and kicked out of array to this piece dish.
More efficient for query note, the information of information recording/table is organized with RBTree or Hash table, reduce the impact on readwrite performance.The read-write of described sector reports an error process as shown in Figure 5:
1), read-write operation is inquired about first this sector and whether has been recorded as bad sector in mapping table.
2) if there is record this sector in mapping table, if be the checking data piece, then can ignore; If non-checking data reads and writes data on the verification sector of arriving, and judges whether to make mistakes.
3) if mistake appears in the read-write check sector, illustrate that then plural data block error appears in this band, can't repair, just declare that array lost efficacy, and allowed the user process; If mistake does not appear in the read-write check sector, directly return these data and get final product.
The bright introducing one-period thread of we is used for scanning disk, in time finds mistake.In order not affect usability, this thread only scans in device free.
Claims (4)
1. the method that shifts of RAID5 data, the implementation procedure that it is characterized in that the method is: when generation is wrong because a small amount of sector corruption produces, the valid data piece is transferred on the checking data piece with band, and above-mentioned sector corruption refers to that the sector read-write reports an error or the periodic scan hard disk is found medium or error in data.
2. the method that shifts of a kind of RAID5 data according to claim 1, it is characterized in that the process that described valid data piece shifts refers to: when a bar damages with a blocks of data piece, if what damage is the True Data piece, through calculating this data block, then writing the checking data piece gets the position and gets on the line item of going forward side by side; If what damage is check block, then needn't calculate this piece, only record and get final product.
3. the method that shifts of a kind of RAID5 data according to claim 1, it is characterized in that: the described sector read-write process of reporting an error is:
1), checks at first whether read-write operation is the bad sector that has recorded;
2) if this sector record is bad sector, and be the checking data piece, then can ignore; If be non-checking data, read and write data on the verification sector of arriving, and judge whether to make mistakes;
3) if mistake appears in the read-write check sector, illustrate that then plural data block error appears in this band, can't repair, just declare that array lost efficacy, and allowed the user process; If mistake does not appear in the read-write check sector, directly return these data and get final product.
4. the method that shifts of a kind of RAID5 data according to claim 1, it is characterized in that: described periodic scan hard disk only carries out in device free.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210459325.7A CN102945191B (en) | 2012-11-15 | 2012-11-15 | A kind of method of RAID5 data batchmove |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210459325.7A CN102945191B (en) | 2012-11-15 | 2012-11-15 | A kind of method of RAID5 data batchmove |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102945191A true CN102945191A (en) | 2013-02-27 |
CN102945191B CN102945191B (en) | 2016-02-24 |
Family
ID=47728139
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201210459325.7A Active CN102945191B (en) | 2012-11-15 | 2012-11-15 | A kind of method of RAID5 data batchmove |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102945191B (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103530069A (en) * | 2013-11-05 | 2014-01-22 | 浪潮(北京)电子信息产业有限公司 | Method for processing bad sectors of RAID5 disk array |
CN103729276A (en) * | 2014-01-28 | 2014-04-16 | 深圳市迪菲特科技股份有限公司 | Method for scanning disk array |
CN104484251A (en) * | 2014-12-11 | 2015-04-01 | 华为技术有限公司 | Method and device for processing faults of hard disk |
CN104598336A (en) * | 2015-02-04 | 2015-05-06 | 北京神州云科数据技术有限公司 | Rebuilding method and device based on RAID (redundant array of independent disk) algorithm |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070294565A1 (en) * | 2006-04-28 | 2007-12-20 | Network Appliance, Inc. | Simplified parity disk generation in a redundant array of inexpensive disks |
CN101576833A (en) * | 2009-06-26 | 2009-11-11 | 杭州华三通信技术有限公司 | Data reconstruction method for Redundant Array of Independent Disks (RAID) and appliance thereof |
CN102508620A (en) * | 2011-12-01 | 2012-06-20 | 浪潮电子信息产业股份有限公司 | Method for processing RAID5 (Redundant Array of Independent Disks) bad sector |
-
2012
- 2012-11-15 CN CN201210459325.7A patent/CN102945191B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070294565A1 (en) * | 2006-04-28 | 2007-12-20 | Network Appliance, Inc. | Simplified parity disk generation in a redundant array of inexpensive disks |
CN101576833A (en) * | 2009-06-26 | 2009-11-11 | 杭州华三通信技术有限公司 | Data reconstruction method for Redundant Array of Independent Disks (RAID) and appliance thereof |
CN102508620A (en) * | 2011-12-01 | 2012-06-20 | 浪潮电子信息产业股份有限公司 | Method for processing RAID5 (Redundant Array of Independent Disks) bad sector |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103530069A (en) * | 2013-11-05 | 2014-01-22 | 浪潮(北京)电子信息产业有限公司 | Method for processing bad sectors of RAID5 disk array |
CN103729276A (en) * | 2014-01-28 | 2014-04-16 | 深圳市迪菲特科技股份有限公司 | Method for scanning disk array |
CN104484251A (en) * | 2014-12-11 | 2015-04-01 | 华为技术有限公司 | Method and device for processing faults of hard disk |
CN104484251B (en) * | 2014-12-11 | 2018-10-02 | 华为技术有限公司 | A kind of processing method and processing device of hard disk failure |
CN104598336A (en) * | 2015-02-04 | 2015-05-06 | 北京神州云科数据技术有限公司 | Rebuilding method and device based on RAID (redundant array of independent disk) algorithm |
CN104598336B (en) * | 2015-02-04 | 2018-04-24 | 深圳神州数码云科数据技术有限公司 | Method for reconstructing and device based on RAID algorithm |
Also Published As
Publication number | Publication date |
---|---|
CN102945191B (en) | 2016-02-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101916173B (en) | RAID (Redundant Array of Independent Disks) based data reading and writing method and system thereof | |
CN103389920B (en) | The self-sensing method of a kind of disk bad block and device | |
CN102708019B (en) | Method, device and system for hard disk data recovery | |
CN102184129B (en) | Fault tolerance method and device for disk arrays | |
CN102023815B (en) | RAID is realized in solid-state memory | |
US7640452B2 (en) | Method for reconstructing data in case of two disk drives of RAID failure and system therefor | |
US9009526B2 (en) | Rebuilding drive data | |
KR100827677B1 (en) | A method for improving I/O performance of RAID system using a matrix stripe cache | |
CN104035830B (en) | A kind of data reconstruction method and device | |
US8356292B2 (en) | Method for updating control program of physical storage device in storage virtualization system and storage virtualization controller and system thereof | |
CN103309775B (en) | A kind of fault-tolerance approach of high-reliability disk array | |
CN102508620B (en) | Method for processing RAID5 (Redundant Array of Independent Disks) bad sector | |
CN101840360A (en) | Rapid reconstruction method and device of RAID (Redundant Array of Independent Disk) system | |
CN102968361A (en) | RAID (Redundant Array of Independent Disk) data self-repairing method | |
CN103718162A (en) | Method and apparatus for flexible raid in ssd | |
US9063869B2 (en) | Method and system for storing and rebuilding data | |
JPH05505264A (en) | Non-volatile memory storage of write operation identifiers in data storage devices | |
CN103049222A (en) | RAID5 (redundant array of independent disk 5) write IO optimization processing method | |
CN101984400B (en) | RAID control method, device and system | |
CN102043685A (en) | RAID (redundant array of independent disk) system and data recovery method thereof | |
CN104484251A (en) | Method and device for processing faults of hard disk | |
CN101609420A (en) | Realize method and the redundant arrays of inexpensive disks and the controller thereof of rebuilding of disc redundant array | |
CN103336727B (en) | The method that NAND flash memory storage equipment is carried out data manipulation | |
CN101866307A (en) | Data storage method and device based on mirror image technology | |
CN102945191B (en) | A kind of method of RAID5 data batchmove |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |