CN106959912A - Disk detection method and device - Google Patents
Disk detection method and device Download PDFInfo
- Publication number
- CN106959912A CN106959912A CN201710131643.3A CN201710131643A CN106959912A CN 106959912 A CN106959912 A CN 106959912A CN 201710131643 A CN201710131643 A CN 201710131643A CN 106959912 A CN106959912 A CN 106959912A
- Authority
- CN
- China
- Prior art keywords
- stick
- data
- disk
- checked
- failure
- 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
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2205—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
- G06F11/2221—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested to test input/output devices or peripheral units
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/22—Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
- G06F11/2273—Test methods
Landscapes
- Engineering & Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
The application provides a kind of disk detection method and device, and applied to the RAID system of storage device, this method includes:When receiving when being used to represent the implementing result of read error of disk return, determine to occur in disk whether the first data in the failure stick of read error have RAID redundancies;If so, then calculating the first data by the data on other disks in the affiliated RAID array of disk;The first data are write to failure stick;If the first data write successfully, at least one stick to be checked is determined based on failure stick;The second data in a stick to be checked at least one described stick to be checked are determined successively, and the second data are write to this stick to be checked;If the second data write-in failure, it is determined that disk failure.Using this method, it is possible to achieve find failed disk in time as far as possible, RAID reliability is improved, the reliability of data is improved;Meanwhile, it is effectively reduced consumption of the disk detection process to system resource and disk I/O process performance.
Description
Technical field
The application is related to technical field of memory, more particularly to a kind of disk detection method and device.
Background technology
With the development of information technology, increasing data are stored in disk, in order to improve data in disk
Reliability, usually using RAID (Redundant Arrays of Independent Disks, RAID) skill
Art carries out redundancy protecting to the data in disk.However, because the vibrations of burst or mechanical breakdown cause disk card to be scratched,
Or the situation that disk card covers the factors such as dirt and magnetic disk media mistake occurs inevitably occurs, when continuous many in disk group
When magnetic disk media mistake occurs in block disk, the speed that RAID is rebuild is relatively low, it is more likely that cause RAID to the redundancy protectings of data
Mechanism failure, causes loss of data.Therefore, by finding magnetic disk media problem in time and disk to media error is repaiied
It is multiple, the reliability of data can be effectively improved.
In existing scheme, disk can be detected using disk preliminary examination survey technology, to find failed disk, and and
Shi Jinhang respective handlings.Specifically, in disk preliminary examination survey technology, disk inspection policies can be preset, for example, setting meter
Calculation machine carries out once reading or writing totally (hereinafter referred to as overall read/write) totally every preset duration to disk, when detecting read/write
When order performs failure, triggering RAID is rebuild.
However, in above-mentioned disk preliminary examination survey technology, due to carrying out overall read/write to disk, so as to cause disk to detect
Process occupying system resources, consume the I O process performance of disk;Also, when disk size is bigger, disk detection process takes
It is longer, occupying system resources it is time-consuming longer, the I O process performance of disk is consumed more;Meanwhile, in extreme circumstances, also may be used
It can occur that the disk just detected, because paroxysmal vibrations or mechanical breakdown cause card to be scratched, and magnetic disk media occurs
The situation of mistake.
The content of the invention
In view of this, the application provides a kind of disk detection method and device, and failure is found in time as far as possible to realize
Disk, improves RAID reliability, improves the reliability of data;Meanwhile, disk detection process is effectively reduced to system resource
With the consumption of disk I/O process performance.
Specifically, the application is achieved by the following technical solution:
According to the first aspect of the embodiment of the present application there is provided a kind of disk detection method, methods described is set applied to storage
Standby RAID system, the storage device is pre-configured with least one RAID array, and the RAID array includes several disks;
Methods described includes:
When receiving when being used to represent the implementing result of read error of disk return, determine occur read error in the disk
Failure stick in the first data whether have RAID redundancies;
If first data have RAID redundancies, by other disks in the affiliated RAID array of the disk
Data calculate first data;
First data are write to the failure stick;
If first data write successfully, at least one stick to be checked is determined based on the failure stick;
The second data in a stick to be checked at least one described stick to be checked are determined successively, are treated to one
Examine stick and write second data;
If the second data write-in failure, it is determined that the disk failure.
According to the second aspect of the embodiment of the present application there is provided a kind of disk detection means, described device is set applied to storage
Standby RAID system, the storage device is pre-configured with least one RAID array, and the RAID array includes several disks,
Described device includes:
Redundancy determining unit, for when receiving when being used to represent the implementing result of read error of disk return, determining institute
Whether the first data stated in the failure stick that read error occurs in disk have RAID redundancies;
First determining unit, if having RAID redundancies for first data, passes through the affiliated RAID of the disk
Data on the disk of other in array calculate first data;
First writing unit, for writing first data to the failure stick;
Determining unit to be checked, if being write successfully for first data, at least one is determined based on the failure stick
Individual stick to be checked;
Second determining unit, for determining second in a stick to be checked at least one described stick to be checked successively
Data;
Second writing unit, for writing second data to one stick to be checked;
Failure determining unit, fails, it is determined that the disk failure if being write for second data.
As seen from the above-described embodiment, RAID array is used for table by actual read operation, receive disk return
When showing the implementing result of read error, further attempt to write script in the failure stick into the failure stick for occurring read error
Data, when writing successfully, the lightweight disk detection that triggering the application is provided, because the detection of lightweight disk is in reality
Triggered after read operation process, it is extra to set disk to detect trigger mechanism, it is possible to achieve to find disk event as early as possible
Barrier, so as to be repaired accordingly in time, improves RAID reliability, improves the reliability of data;Simultaneously as in the application
In the lightweight disk detection process of offer, the stick to be checked of specified range is detected, compared to overall detection, Ke Yiyou
Consumption of the reduction disk detection process in effect ground to system resource and disk I/O process performance.
Brief description of the drawings
Fig. 1 is one embodiment flow chart of the application disk detection method;
Fig. 2 is a kind of hardware structure diagram of storage device where the application disk detection means;
Fig. 3 is one embodiment block diagram of the application disk detection means.
Embodiment
Here exemplary embodiment will be illustrated in detail, its example is illustrated in the accompanying drawings.Following description is related to
During accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represent same or analogous key element.Following exemplary embodiment
Described in embodiment do not represent all embodiments consistent with the application.On the contrary, they be only with it is such as appended
The example of the consistent apparatus and method of some aspects be described in detail in claims, the application.
It is the purpose only merely for description specific embodiment in term used in this application, and is not intended to be limiting the application.
" one kind ", " described " and "the" of singulative used in the application and appended claims are also intended to including majority
Form, unless context clearly shows that other implications.It is also understood that term "and/or" used herein refers to and wrapped
It may be combined containing one or more associated any or all of project listed.
It will be appreciated that though various information, but this may be described using term first, second, third, etc. in the application
A little information should not necessarily be limited by these terms.These terms are only used for same type of information being distinguished from each other out.For example, not departing from
In the case of the application scope, the first information can also be referred to as the second information, similarly, and the second information can also be referred to as
One information.Depending on linguistic context, word as used in this " if " can be construed to " ... when " or " when ...
When " or " in response to determining ".
RAID technique is that multiple independent physical disks combine in different ways, forms a virtual magnetic
Disk.By using RAID technique, it is possible to achieve concurrent reading and concurrent writing data, the access rate of data is improved, meanwhile, RAID technique fortune
Redundancy protecting is carried out to data with technologies such as mirror image, even-odd checks, the reliability of data is drastically increased.
The Method of Data Organization that one RAID array can be included in multiple member's disks, RAID array includes stick and bar
Band.Wherein, stick be RAID array manage memory space least unit, create RAID array when, including member
The memory space of disk is divided into the adjacent block in equal in magnitude, address by default bar block size, and these equal in magnitude, addresses are adjacent
Block be referred to as stick;Band is the set of the related stick in position on multiple member's disks of RAID array, according to RAID
Difference, RAID implementation is different, and the number of member's disk is different in RAID array, and member's Disk State is different and RAID is calculated
Method is different, and the RAID redundancies of data are also different in stick.
In RAID technique, processing of the RAID array to read/write command is handled according to band, works as RAID array
Receive after the read/write command that upper layer software (applications) is issued, band to be operated determined based on the address carried in the read/write command,
Afterwards based on factors such as RAID, RAID algorithm, member's Disk States, the read/write command is split as to be directed in the band
The read/write command of the corresponding stick of one or more member's disks, corresponding member's disk is issued by the read/write command after fractionation
Perform.Subsequently, member's disk performs the read/write command received, and implementing result is back into RAID array.
In this application, member's disk that RAID array can be included based on it is to the implementing result of read command, further
The detection of lightweight disk is triggered, " detection of lightweight disk " mentioned here refers to enter in the range of the specified stick to member's disk
Row detection, compared to existing disk preliminary examination survey technology, it is possible to achieve find failed disk in time as far as possible, improves RAID's
Reliability, improves the reliability of data;Meanwhile, disk detection process is effectively reduced to system resource and disk I/O process performance
Consumption.
It is as follows, in order that those skilled in the art can understand, be visually known the disk detection method of the application offer
How to realize and find failed disk in time as far as possible, improve RAID reliability, improve the reliability of data;Meanwhile, effectively
Ground reduces consumption of the disk detection process to system resource and disk I/O process performance, enumerates following embodiments and specifically describes this Shen
The disk detection method please provided.
Fig. 1 is referred to, is one embodiment flow chart of the application disk detection method, this method can apply to storage
RAID array in the RAID system of equipment, may comprise steps of:
Step 101:When receiving when being used to represent the implementing result of read error of disk return, determine to read in disk
Whether the first data in the failure stick of mistake have RAID redundancies, if so, then performing step 102, otherwise, perform step
106。
After RAID array receives the read/write command that upper layer software (applications) is issued, based on the address carried in the read/write command
Band to be operated is determined, afterwards based on factors such as RAID, RAID algorithm, member's Disk States, the read/write command is torn open
It is divided into the read/write command for the corresponding stick of one or more member's disks in the band, the read/write command after fractionation is sent out
Performed to corresponding member's disk.Subsequently, member's disk performs the read/write command received, if treated in some member's disk
Read/write stick failure, then, member's disk can return to the implementing result for representing read/write errors to RAID array.
In this application, when RAID array receives the implementing result for representing read error of disk return, not
The disk is directly defined as failed disk, and can be based on disk bad sector and remap mechanism, attempts to carry out the disk
Repair, further determine that whether the disk unavailable according to the result of reparation, i.e., disk whether failure.
Specifically, it is generally the case that when disk dispatches from the factory, disk manufacturer just retains a part of sector in disk, should
Partial sector is invisible to the user of disk, and disk can be using the partial sector as alternate sector, when disk is wrongly write
Mistake, the bad sector for occurring write error can be mapped to alternate sector by disk automatically, and the address that will point to the bad sector is replaced
Change the address for pointing to alternate sector into, subsequently, disk can write data into the alternate sector for mapped completion again, subsequently
Also bad sector will not be visited again.Mechanism is remapped based on above-mentioned described disk bad sector, upper layer software (applications) can't be perceived
Write error occurs for disk, it is thus regarded that disk is normal, subsequently, until when the alternate sector of disk is finished, and upper layer software (applications) just can be with
Perceive disk and occur write error, so that it is determined that disk failure.So, in this application, returned when RAID array receives disk
During the implementing result for representing read error returned, write in the failure stick that read error can further occur into the disk
Data, according to the write-in result of data can determine as precisely as possible the disk whether failure.
It should be noted that the reliability in order to avoid influenceing data, when writing data into failure stick, Ke Yixiang
The data of script in the failure stick are write in failure stick.Based on this, when RAID array receive disk return be used for table
When showing the implementing result of read error, it may further determine that whether the data in the failure stick that read error occurs in the disk have
There are RAID redundancies, " whether the data in failure stick have RAID redundancies " mentioned here refers to, in failure stick
Whether data can be calculated by the data with the failure stick in the corresponding stick in other member's disks of same band
Go out.It should be noted that for convenience, the data in failure stick are referred to as into the first data in the application.
As RAID is different, the storage mode of data is also different in disk array, therefore, it can based on different
RAID and member's Disk State, determine whether the data in failure stick have RAID superfluous using different RAID algorithms
Yu Xing, specific to the RAID algorithm of different RAIDs, those skilled in the art may refer to correlation of the prior art and retouch
State, the application is not detailed to this.
In this application, when it is determined that the first data in failure stick have RAID redundancies, you can to continue executing with
The flow of data is write subsequently into the failure stick, you can to continue executing with step 102;When it is determined that in failure stick first
When data do not have redundancy, i.e., the first data in failure stick can not be determined, based on foregoing description, then can not performed follow-up
The flow of data is write into the failure stick, step 106 now can be further performed.
Step 102:The first data are calculated by the data on other disks in the affiliated RAID array of disk.
As RAID is different, the storage mode of data is also different in disk array, then, can be according to RAID
And member's Disk State, it is determined that specific RAID algorithm, so that based on the RAID algorithm, it is same by being located at failure stick
The data in corresponding stick in other member's disks of band calculate the first data in failure stick, specific to not
With the RAID algorithm of RAID, those skilled in the art may refer to associated description of the prior art, the application to this not
It is described in detail.
Step 103:The first data are write into failure stick, if the write-in failure of the first data, performs step 106;If
First data write successfully, then perform step 104.
Mechanism is remapped based on above-mentioned described disk bad sector, if the write-in failure of the first data, it is considered that should
Alternate sector is not present in disk, may thereby determine that the disk is unavailable, at this point it is possible to continue executing with step 106.
If the first data write successfully, it is considered that also have remaining alternate sector in the disk, also, to failure
During stick writes the first data, trigger disk bad sector and remapped, i.e., the disk is repaired automatically, should
Disk still can use.
So far, disk selfreparing success, and upper layer software (applications) does not perceive the process that disk carries out selfreparing, still may be used
To continue to carry out data read-write operation to disk.But now there is failure stick in disk has turned into inevitable actual feelings
Condition, and based on the characteristic of magnetic disk media mistake, i.e., because the vibrations of burst or disk mechanical breakdown cause disk card to be drawn
The magnetic disk media mistake that the factors such as wound, dust occur, physically with continuity, i.e., the adjacent stick of failure stick is also event
The probability for hindering stick is larger, and more than one failure stick is likely that there are in disk.
Based on this, the application is in execution of step 103, after the first data write successfully, and it is light that triggering the application is proposed
Disk testing mechanism is measured, disk failure is found in time as far as possible to realize, so as to be repaired accordingly in time, RAID is improved
Reliability, improve data reliability.Specifically, in execution of step 103, after the first data write successfully, performing step
Rapid 104.
Step 104:At least one stick to be checked is determined based on failure stick.
, can be based on the failure for occurring read error in the application based on the characteristic of above-mentioned described magnetic disk media mistake
Stick determines at least one stick to be checked.
Specifically, in this application, can pre-set an offset, the offset can be using amount of capacity to be single
Position, based on the offset, can also be entered line displacement at failure stick, obtains at least one to be checked in units of stick number
Stick.
In one embodiment, if the offset in units of amount of capacity, it is necessary to explanation, the offset can be bar
The integral multiple of block size, for example, it is assumed that bar block size is 32KB, offset could be arranged to 64KB.Accordingly, when offset to hold
When to measure size be unit, offset can also be converted in units of stick number, for example, when offset is 64KB, can be with
It is 2 sticks to be equal to offset.
Assuming that failure stick is stick 3 (starting stick is stick 0), then the offset (2 sticks) can be based on, with event
Hinder centered on stick, offset before and after carrying out respectively, obtain 4 sticks to be checked, respectively stick 1, stick 2, and stick 4 and bar
Block 5.
If it should be noted that based on the default offset, when being offset before and after being carried out respectively centered on failure stick,
If offseting stick in the absence of enough, actual shifts situation can be based on, stick to be checked is determined.For example, it is assumed that failure stick
For stick 0, other sticks are had no before the failure stick, then can be based only upon offset, enter line displacement backward from stick 0, obtain 2
Individual stick to be checked, respectively stick 1, stick 2.Again for example, it is assumed that failure stick is stick 1, only one of which before the failure stick
Stick, then can be based on offset, from 1 stick of biased forwards at stick 1,2 sticks are offset backward, 3 bars to be checked are obtained
Block, respectively stick 0, stick 2, and stick 3.
It is above-mentioned as just citing, other situation the application are no longer described one by one.
Step 105:The second data in a stick to be checked at least one stick to be checked are determined successively, to this
The second data are write in stick to be checked, if the write-in failure of the second data, performs step 106.
Based on the first data same consideration with script in Write fault stick in the above-mentioned described stick to failure,
I.e. for the reliability for ensureing data, in the application, during being detected to stick to be checked, it can determine first to be checked
Data in stick, the data of script in stick to be checked are write to the stick to be checked.It should be noted that for convenience,
The data in stick to be checked are referred to as the second data in the application.
In the application, at least one stick to be checked obtained in step 104 can be handled successively.For example, it is assumed that
3 sticks to be checked are obtained in step 104, respectively stick 0, stick 2, and stick 3 can then be determined in stick 0 first
Second data, afterwards, the second data are write into stick 0, if the write-in failure of the second data, performs step 106.
Specifically, in an optional implementation, it can determine whether the second data in stick 0 have first
RAID redundancies, if the second data in the stick 0 have RAID redundancies, can continue be based on RAID algorithm, by with bar
Data in the corresponding stick that block 0 is located in other member's disks of same band calculate the second data in stick 0, it
Afterwards, second data are write to stick 0, if second data write-in failure, performs step 106.
If in addition, the second data in the stick 0 do not have RAID redundancies, step 106 can be continued executing with.
In addition, in above process, if the second data in stick 0 write successfully, can continue to calculate stick 2
In the second data, afterwards, second data are write into stick 2, until success writes the of script in stick 3 to stick 3
During two data, it is believed that disk is normal.
In another optional implementation, the second data in stick 0 can be read first, if in stick 0
Two digital independents fail, then determine whether the second data in stick 0 have RAID redundancies.
If in addition, the second digital independent in stick 0 is successful, can continue to read the second data in stick 2, until
When the second data in stick 3 are read in success, it is believed that disk is normal.
It should be noted that the above-mentioned described stick 0 that is primarily based on is detected, detected secondly based on stick 2,
Order that stick 3 detected is again based on as just citing, in practical application, at least one stick to be checked is detected
Order be not restricted.
Step 106:Determine disk failure.
As seen from the above-described embodiment, RAID array is used for table by actual read operation, receive disk return
When showing the implementing result of read error, further attempt to write script in the failure stick into the failure stick for occurring read error
Data, when writing successfully, the lightweight disk detection that triggering the application is provided, because the detection of lightweight disk is in reality
Triggered after read operation process, it is extra to set disk to detect trigger mechanism, it is possible to achieve to find disk event as early as possible
Barrier, so as to be repaired accordingly in time, improves RAID reliability, improves the reliability of data;Simultaneously as in the application
In the lightweight disk detection process of offer, the stick to be checked of specified range is detected, compared to overall detection, Ke Yiyou
Consumption of the reduction disk detection process in effect ground to system resource and disk I/O process performance.
Embodiment with foregoing disk detection method is corresponding, and present invention also provides the embodiment of disk detection means.
The embodiment of the application disk detection means can be applied in storage device, such as on computer.Device embodiment
It can be realized, can also be realized by way of hardware or software and hardware combining by software.Exemplified by implemented in software, one is used as
Device on individual logical meaning, is by corresponding computer in nonvolatile memory by the processor of storage device where it
Programmed instruction reads what operation in internal memory was formed.For hardware view, as shown in Fig. 2 being the application disk detection means
A kind of hardware structure diagram of place storage device, except the processor 21 shown in Fig. 2, internal memory 22, network interface 23 and it is non-easily
Outside the property lost memory 24, the storage device in embodiment where device may be used also generally according to the actual functional capability of the storage device
Including other hardware, to be repeated no more to this.
Fig. 3 is refer to, is one embodiment block diagram of the application disk detection means, the device can apply to storage and set
RAID array in standby RAID system, the device can include:Redundancy determining unit 31, the first determining unit 32, first are write
Enter unit 33, determining unit to be checked 34, the second determining unit 35, the second writing unit 36, failure determining unit 37.
Wherein, the redundancy determining unit 31, can be used for when the execution for being used to represent read error for receiving disk return
When as a result, determine to occur in the disk whether the first data in the failure stick of read error have RAID redundancies;
First determining unit 32, if can be used for first data has RAID redundancies, passes through the disk
Data in affiliated RAID array on other disks calculate first data;
First writing unit 33, can be used for writing first data to the failure stick;
The determining unit 34 to be checked, writes successfully if can be used for first data, true based on the failure stick
At least one fixed stick to be checked;
Second determining unit 35, can be used for determining a stick to be checked at least one described stick to be checked successively
In the second data;
Second writing unit 36, can be used for writing second data to one stick to be checked;
The failure determining unit 37, if can be used for the second data write-in failure, it is determined that the disk failure.
In one embodiment, the determining unit to be checked 34 can be specifically for:
Line displacement is entered at the failure stick based on default offset, at least one stick to be checked is obtained.
In one embodiment, second determining unit 35 can include (not showed that in Fig. 3):
Redundancy determination subelement, for determining the in a stick to be checked at least one described stick to be checked successively
Whether two data have RAID redundancies;
Data determination subelement, if there is RAID redundancies for second data, by belonging to the disk
Data on the disk of other in RAID array calculate second data.
In one embodiment, the redundancy determination subelement can include (not showed that in Fig. 3):
Subelement is read, for the second number being successively read in a stick to be checked at least one described stick to be checked
According to;
Determination subelement, if for second digital independent failure, it is determined that second data have RAID redundancies
Property.
In one embodiment, described device can also include (not showed that in Fig. 3):
Reading unit, if for second digital independent success, continuing to read in another described stick to be checked
Second data, until when the second digital independent in each described stick to be checked is successful, determining that the disk is normal.
In one embodiment, the failure determining unit 37 can be also used for:
If first data do not have RAID redundancies, it is determined that the disk failure.
In one embodiment, the failure determining unit 37 can be also used for:
If the first data write-in failure, it is determined that the disk failure.
The function of unit and the implementation process of effect specifically refer to correspondence step in the above method in said apparatus
Implementation process, will not be repeated here.
For device embodiment, because it corresponds essentially to embodiment of the method, so related part is real referring to method
Apply the part explanation of example.Device embodiment described above is only schematical, wherein described be used as separating component
The unit of explanation can be or may not be physically separate, and the part shown as unit can be or can also
It is not physical location, you can with positioned at a place, or can also be distributed on multiple NEs.Can be according to reality
Selection some or all of module therein is needed to realize the purpose of application scheme.Those of ordinary skill in the art are not paying
In the case of going out creative work, you can to understand and implement.
The preferred embodiment of the application is the foregoing is only, not to limit the application, all essences in the application
God is with principle, and any modifications, equivalent substitutions and improvements done etc. should be included within the scope of the application protection.
Claims (14)
1. a kind of disk detection method, it is characterised in that methods described is applied to the disk array RAID system of storage device, institute
State storage device and be pre-configured with least one RAID array, the RAID array includes several disks;Methods described includes:
When receiving when being used to represent the implementing result of read error of disk return, determine that the event of read error occurs in the disk
Hinder whether the first data in stick have RAID redundancies;
If first data have RAID redundancies, pass through the data on other disks in the affiliated RAID array of the disk
Calculate first data;
First data are write to the failure stick;
If first data write successfully, at least one stick to be checked is determined based on the failure stick;
The second data in a stick to be checked at least one described stick to be checked are determined successively, to one bar to be checked
Block writes second data;
If the second data write-in failure, it is determined that the disk failure.
2. according to the method described in claim 1, it is characterised in that described to determine that at least one is to be checked based on the failure stick
Stick includes:
Line displacement is entered at the failure stick based on default offset, at least one stick to be checked is obtained.
3. according to the method described in claim 1, it is characterised in that described to determine successively at least one described stick to be checked
The second data in one stick to be checked, including:
Determine whether the second data in a stick to be checked at least one described stick to be checked have RAID redundancies successively
Property;
If second data have RAID redundancies, pass through the data on other disks in the affiliated RAID array of the disk
Calculate second data.
4. method according to claim 3, it is characterised in that described to determine successively at least one described stick to be checked
Whether the second data in one stick to be checked have RAID redundancies, including:
It is successively read the second data in a stick to be checked at least one described stick to be checked;
If the second digital independent failure, it is determined that whether second data have RAID redundancies.
5. method according to claim 4, it is characterised in that methods described also includes:
If the second digital independent success, continues to read the second data in another described stick to be checked, until each
When the second digital independent in the individual stick to be checked is successful, determine that the disk is normal.
6. according to the method described in claim 1, it is characterised in that methods described also includes:
If first data do not have RAID redundancies, it is determined that the disk failure.
7. according to the method described in claim 1, it is characterised in that methods described also includes:
If the first data write-in failure, it is determined that the disk failure.
8. a kind of disk detection means, it is characterised in that described device is applied to the RAID system of storage device, the storage is set
Standby to be pre-configured with least one RAID array, the RAID array includes several disks, and described device includes:
Redundancy determining unit, for when receiving when being used to represent the implementing result of read error of disk return, determining the magnetic
Occur whether the first data in the failure stick of read error have RAID redundancies in disk;
First determining unit, if having RAID redundancies for first data, passes through the affiliated RAID array of the disk
In data on other disks calculate first data;
First writing unit, for writing first data to the failure stick;
Determining unit to be checked, if being write successfully for first data, determines that at least one is treated based on the failure stick
Examine stick;
Second determining unit, for determining the second number in a stick to be checked at least one described stick to be checked successively
According to;
Second writing unit, for writing second data to one stick to be checked;
Failure determining unit, fails, it is determined that the disk failure if being write for second data.
9. device according to claim 8, it is characterised in that the determining unit to be checked specifically for:
Line displacement is entered at the failure stick based on default offset, at least one stick to be checked is obtained.
10. device according to claim 8, it is characterised in that second determining unit includes:
Redundancy determination subelement, for determining the second number in a stick to be checked at least one described stick to be checked successively
According to whether with RAID redundancies;
Data determination subelement, it is affiliated RAID gusts by the disk if there is RAID redundancies for second data
Data on the disk of other in row calculate second data.
11. device according to claim 10, it is characterised in that the redundancy determination subelement includes:
Subelement is read, for the second data being successively read in a stick to be checked at least one described stick to be checked;
Determination subelement, if for second digital independent failure, it is determined that second data have RAID redundancies.
12. device according to claim 11, it is characterised in that described device also includes:
Reading unit, if for second digital independent success, continuing to read second in another described stick to be checked
Data, until when the second digital independent in each described stick to be checked is successful, determining that the disk is normal.
13. device according to claim 8, it is characterised in that the failure determining unit is additionally operable to:
If first data do not have RAID redundancies, it is determined that the disk failure.
14. device according to claim 8, it is characterised in that the failure determining unit is additionally operable to:
If the first data write-in failure, it is determined that the disk failure.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710131643.3A CN106959912B (en) | 2017-03-07 | 2017-03-07 | Disk detection method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710131643.3A CN106959912B (en) | 2017-03-07 | 2017-03-07 | Disk detection method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106959912A true CN106959912A (en) | 2017-07-18 |
CN106959912B CN106959912B (en) | 2020-03-24 |
Family
ID=59470610
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710131643.3A Active CN106959912B (en) | 2017-03-07 | 2017-03-07 | Disk detection method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106959912B (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107544860A (en) * | 2017-08-29 | 2018-01-05 | 新华三技术有限公司 | A kind of data in magnetic disk detection method and device |
CN109582499A (en) * | 2018-11-27 | 2019-04-05 | 杭州宏杉科技股份有限公司 | Manage metadata restorative procedure and device |
CN111124251A (en) * | 2018-10-30 | 2020-05-08 | 伊姆西Ip控股有限责任公司 | Method, apparatus and computer readable medium for I/O control |
CN111274070A (en) * | 2019-11-04 | 2020-06-12 | 华为技术有限公司 | Hard disk detection method and device and electronic equipment |
CN111816239A (en) * | 2019-04-12 | 2020-10-23 | 杭州宏杉科技股份有限公司 | Disk detection method and device, electronic equipment and machine-readable storage medium |
CN112817520A (en) * | 2020-12-31 | 2021-05-18 | 杭州宏杉科技股份有限公司 | Data disk refreshing method and device |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101527142A (en) * | 2009-04-17 | 2009-09-09 | 杭州华三通信技术有限公司 | Reading-writing method of data in redundant arrays of inexpensive disks (RAID) and equipment thereof |
CN103678048A (en) * | 2013-11-29 | 2014-03-26 | 华为技术有限公司 | Repair method and repair device for redundant array of independent disks (RAID) and storage equipment |
CN103699457A (en) * | 2013-09-26 | 2014-04-02 | 深圳市泽云科技有限公司 | Method and device for restoring disk arrays based on stripping |
CN104850359A (en) * | 2015-05-29 | 2015-08-19 | 浙江宇视科技有限公司 | RAID array rebuilding method and device |
US9405617B1 (en) * | 2011-02-11 | 2016-08-02 | Western Digital Technologies, Inc. | System and method for data error recovery in a solid state subsystem |
-
2017
- 2017-03-07 CN CN201710131643.3A patent/CN106959912B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101527142A (en) * | 2009-04-17 | 2009-09-09 | 杭州华三通信技术有限公司 | Reading-writing method of data in redundant arrays of inexpensive disks (RAID) and equipment thereof |
US9405617B1 (en) * | 2011-02-11 | 2016-08-02 | Western Digital Technologies, Inc. | System and method for data error recovery in a solid state subsystem |
CN103699457A (en) * | 2013-09-26 | 2014-04-02 | 深圳市泽云科技有限公司 | Method and device for restoring disk arrays based on stripping |
CN103678048A (en) * | 2013-11-29 | 2014-03-26 | 华为技术有限公司 | Repair method and repair device for redundant array of independent disks (RAID) and storage equipment |
CN104850359A (en) * | 2015-05-29 | 2015-08-19 | 浙江宇视科技有限公司 | RAID array rebuilding method and device |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107544860A (en) * | 2017-08-29 | 2018-01-05 | 新华三技术有限公司 | A kind of data in magnetic disk detection method and device |
CN111124251A (en) * | 2018-10-30 | 2020-05-08 | 伊姆西Ip控股有限责任公司 | Method, apparatus and computer readable medium for I/O control |
CN111124251B (en) * | 2018-10-30 | 2023-08-29 | 伊姆西Ip控股有限责任公司 | Method, apparatus and computer readable medium for I/O control |
CN109582499A (en) * | 2018-11-27 | 2019-04-05 | 杭州宏杉科技股份有限公司 | Manage metadata restorative procedure and device |
CN111816239A (en) * | 2019-04-12 | 2020-10-23 | 杭州宏杉科技股份有限公司 | Disk detection method and device, electronic equipment and machine-readable storage medium |
CN111816239B (en) * | 2019-04-12 | 2022-11-11 | 杭州宏杉科技股份有限公司 | Disk detection method and device, electronic equipment and machine-readable storage medium |
CN111274070A (en) * | 2019-11-04 | 2020-06-12 | 华为技术有限公司 | Hard disk detection method and device and electronic equipment |
CN111274070B (en) * | 2019-11-04 | 2021-10-15 | 华为技术有限公司 | Hard disk detection method and device and electronic equipment |
CN112817520A (en) * | 2020-12-31 | 2021-05-18 | 杭州宏杉科技股份有限公司 | Data disk refreshing method and device |
Also Published As
Publication number | Publication date |
---|---|
CN106959912B (en) | 2020-03-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106959912A (en) | Disk detection method and device | |
US20050229033A1 (en) | Disk array controller and information processing apparatus | |
US7477477B2 (en) | Hard disk drive and command execution method | |
US8090981B1 (en) | Auto-configuration of RAID systems | |
US7330932B2 (en) | Disk array with spare logic drive created from space physical drives | |
CN100530125C (en) | Safety storage method for data | |
US20040250017A1 (en) | Method and apparatus for selecting among multiple data reconstruction techniques | |
US7770076B2 (en) | Multi-platter disk drive controller and methods for synchronous redundant data operations | |
US20080178040A1 (en) | Disk failure restoration method and disk array apparatus | |
US20030198100A1 (en) | Method of controlling the operation of non-volatile semiconductor memory chips | |
US20040030831A1 (en) | Manipulating data in a data storage device using an auxiliary memory device | |
JPH05505264A (en) | Non-volatile memory storage of write operation identifiers in data storage devices | |
EP0686981B1 (en) | Method for testing large memory arrays during system initialization | |
CN111816239B (en) | Disk detection method and device, electronic equipment and machine-readable storage medium | |
US7308601B2 (en) | Program, method and apparatus for disk array control | |
GB2402770A (en) | Writing version checking data for a data file onto two data storage systems. | |
CN108170375B (en) | Overrun protection method and device in distributed storage system | |
JP4933722B2 (en) | Disk control device, disk patrol method, and disk patrol program | |
US20090138656A1 (en) | Method of skipping synchronization process for initialization of RAID1 device | |
US6862661B2 (en) | Object oriented approach to a redundant array storage system | |
JP5505329B2 (en) | Disk array device and control method thereof | |
JP6957845B2 (en) | Storage control device and storage device | |
JP5601053B2 (en) | Control device, control module, and control method | |
US20030103392A1 (en) | Method of controlling the operation of non-volatile semiconductor memory chips | |
JP3597766B2 (en) | Disk array device control method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |