CN104424049B - A kind of data processing method and electronic equipment - Google Patents
A kind of data processing method and electronic equipment Download PDFInfo
- Publication number
- CN104424049B CN104424049B CN201310392475.5A CN201310392475A CN104424049B CN 104424049 B CN104424049 B CN 104424049B CN 201310392475 A CN201310392475 A CN 201310392475A CN 104424049 B CN104424049 B CN 104424049B
- Authority
- CN
- China
- Prior art keywords
- subelement
- state
- electronic equipment
- module
- data information
- 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.)
- Active
Links
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The invention discloses a kind of data processing methods, and applied in electronic equipment, the electronic equipment includes more than one storage unit, the described method includes:Subregion is carried out to the storage unit, and obtains more than one first subelement and more than one second subelement;When detecting that first subelement is in first state, whole copy data information of first subelement are obtained;Whole copy data information of first subelement are stored to second subelement.The present invention further simultaneously discloses a kind of electronic equipment.Technical solution using the present invention, can shorten the time of data recovery, and make full use of the transmission performance of I/O interfaces.
Description
Technical field
The present invention relates to data processing technique more particularly to a kind of data processing method and electronic equipments.
Background technology
In distributed memory system, in order to ensure the reliability of data, the storage mode of more copies can be generally used.But
It is that, with the expansion of memory node capacity, when some disk failures in memory node, substantial amounts of data can be caused
Recovery operation.
At present, data recovery operation is mainly in the following ways:Record the master backup between primary disk and backup diskette
Relation after master disk failure, just according to the copy data information in backup diskette, is one by one recovered data.However, work as
When the data of magnanimity are stored in primary disk and backup diskette, can then be consumed by way of recovering one by one to data compared with
The long time, also, the capacity per data is too small, can not make full use of the input/output between disk(I/O, In/Out)
The transmission performance of interface.
The content of the invention
In view of this, it is a primary object of the present invention to provide a kind of data processing method and electronic equipment, can shorten
The time that data are recovered, and make full use of the transmission performance of I/O interfaces.
In order to achieve the above objectives, the technical proposal of the invention is realized in this way:
A kind of data processing method, applied in electronic equipment, the electronic equipment includes more than one storage unit, institute
The method of stating includes:Subregion is carried out to the storage unit, and obtains more than one first subelement and more than one second son
Unit;When detecting that first subelement is in first state, whole copy data information of first subelement are obtained;
Whole copy data information of first subelement are stored to second subelement.
A kind of electronic equipment, the electronic equipment include more than one storage unit, and the electronic equipment includes:Subregion mould
Block, acquisition module and processing module;Wherein,
The division module, for the storage unit carry out subregion, and obtain more than one first subelement and
More than one second subelement;
During for detecting that first subelement is in first state, it is single to obtain first son for the acquisition module
Whole copy data information of member;
The processing module, it is single to the described second son for storing whole copy data information of first subelement
Member.
In the embodiment of the present invention, subregion is carried out to more than one storage unit in electronic equipment, and obtains more than one
First subelement and more than one second subelement;When detecting that first subelement is in first state, described in acquisition
Whole copy data information of first subelement;Whole copy data information of first subelement are stored to described second
Subelement;It so, it is possible to shorten the time that data are recovered, and make full use of the transmission performance of I/O interfaces.
Description of the drawings
Fig. 1 is the flow diagram of the data processing method of the embodiment of the present invention one;
Fig. 2 is the flow diagram of the data processing method of the embodiment of the present invention two;
Fig. 3 is the flow diagram of the data processing method of the embodiment of the present invention three;
Fig. 4 is the flow diagram of the data processing method of the embodiment of the present invention four;
Fig. 5 is the flow diagram of the data processing method of the embodiment of the present invention five;
Fig. 6 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention one;
Fig. 7 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention two;
Fig. 8 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention three;
Fig. 9 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention four;
Figure 10 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention five;
Figure 11 is the structure diagram of storage unit in electronic equipment of the embodiment of the present invention.
Specific embodiment
In order to more fully hereinafter understand the features of the present invention and technology contents, below in conjunction with the accompanying drawings to the reality of the present invention
It is now described in detail, appended attached drawing purposes of discussion only for reference, is not used for limiting the present invention.
Fig. 1 is the flow diagram of the data processing method of the embodiment of the present invention, the data processing method in the present embodiment
Applied in electronic equipment, the electronic equipment includes more than one storage unit, in a preferred embodiment of the invention, number
Comprise the following steps according to processing method,
Step 101:Subregion is carried out to the storage unit, and obtain more than one first subelement and more than one the
Two subelements.
Here, the storage unit can be any form of storage medium such as disk.
It carries out subregion to residing storage unit to refer to the storage unit carrying out logical partition, for example, storage unit is
One piece of hard disk in server after the hard disk is carried out logical partition, can obtain the separated sub-disk of more than one logic.
In the present embodiment, the separated sub-disk of above-mentioned logic is divided into two classes, one kind is the first subelement, and another kind of is
Two word cells;Wherein, the first subelement is available storage region, can be with read/write data in the first subelement;Second son is single
Member is reserved storage region, when the first subelement breaks down, can store the first subelement by the second subelement
Copy data information.
Step 102:When detecting that first subelement is in first state, all secondary of first subelement is obtained
Notebook data information.
Here, first state refers to that the first subelement is in unusable state, such as the first subelement is in damage shape
State or malfunction.
When the first subelement is in first state, the data in the first subelement are also at first state accordingly, such as
This from spare electronic equipment, it is necessary to obtain whole copy data information of the first subelement.
Step 103:Whole copy data information of first subelement are stored to second subelement.
In the present embodiment, when the first subelement is in first state, just by whole copy data information of the first subelement
It stores to the second subelement, the data message in fast quick-recovery electronic equipment, and makes full use of the transmission performance of I/O interfaces.
Fig. 2 is the flow diagram of the data processing method of the embodiment of the present invention, the data processing method in the present embodiment
Applied in electronic equipment, the electronic equipment includes more than one storage unit, in a preferred embodiment of the invention, number
Comprise the following steps according to processing method,
Step 201:Subregion is carried out to the storage unit, and obtain more than one first subelement and more than one the
Two subelements.
Here, the storage unit can be any form of storage medium such as disk.
It carries out subregion to residing storage unit to refer to the storage unit carrying out logical partition, for example, storage unit is
One piece of hard disk in server after the hard disk is carried out logical partition, can obtain the separated sub-disk of more than one logic.
In the present embodiment, the separated sub-disk of above-mentioned logic is divided into two classes, one kind is the first subelement, and another kind of is
Two word cells;Wherein, the first subelement is available storage region, can be with read/write data in the first subelement;Second son is single
Member is reserved storage region, when the first subelement breaks down, can store the first subelement by the second subelement
Copy data information.
Step 202:For first subelement setting first flag and it is that second subelement sets the second mark
Know.
Specifically, it is respectively that more than one first subelement sets first flag, for example, dividing the storage unit
Qu Hou obtains three the first subelements, then the first flag of these three the first subelements is respectively set to 1,2,3;Respectively one
A above second subelement sets second identifier, for example, after carrying out subregion to the storage unit, it is single to obtain two second sons
Member, then the second identifier of the two the second subelements be respectively set to A, B.
In the present embodiment, first flag and any combination that second identifier can be following character:Number, letter, symbol
Deng.
Step 203:When detecting that first subelement is in first state, all secondary of first subelement is obtained
Notebook data information.
Here, first state refers to that the first subelement is in unusable state, such as the first subelement is in damage shape
State or malfunction.
When the first subelement is in first state, the data in the first subelement are also at first state accordingly, such as
This from spare electronic equipment, it is necessary to obtain whole copy data information of the first subelement.
Step 204:Whole copy data information of first subelement are stored to second subelement.
Step 205:By the second identifier of second subelement be arranged to first subelement first flag and
Second subelement is converted into first subelement.
Whole copy data information of first subelement are stored to second subelement, the second subelement
The function of being realized just is equivalent to the function that the first subelement is realized, for example, the first subelement stores A data, client is read
It takes during A data, it is necessary to the first subelement be accessed, when the first subelement is in first state, just by the whole of the first subelement
Copy data information is stored to the second subelement, in this way, the second subelement store A data, client read A data when, it is necessary to
Access the second subelement rather than the first subelement.
Preferably, when the number of second subelement is less than or equal to default threshold value, search in the second state
The first subelement;It is single that the first flag of the first subelement in the second state found is arranged to second son
The second identifier of member;The first subelement in the second state found is converted into the second subelement.
When the number of second subelement is less than certain amount, it can not just be stored when the first subelement is in first state
Whole copy data information of first subelement, for this reason, it may be necessary to search the first subelement being in idle condition, the present embodiment will
Idle state is known as the second state, then the first subelement being in idle condition is converted to the second subelement, meanwhile, it will convert
The second identifier of the second subelement is arranged to for the first flag of the first subelement of the second subelement.
In the present embodiment, when the first subelement is in first state, just by whole copy data information of the first subelement
It stores to the second subelement, the data message in fast quick-recovery electronic equipment, and makes full use of the transmission performance of I/O interfaces;
Also, the second subelement is converted into the first subelement and the second identifier of the second subelement is arranged to the first subelement
First flag, can realize client accurately access needed for data.
Fig. 3 is the flow diagram of the data processing method of the embodiment of the present invention, the data processing method in the present embodiment
Applied in electronic equipment, the electronic equipment includes more than one storage unit, in a preferred embodiment of the invention, number
Comprise the following steps according to processing method,
Step 301:Subregion is carried out to the storage unit, and obtain more than one first subelement and more than one the
Two subelements.
Here, the storage unit can be any form of storage medium such as disk.
It carries out subregion to residing storage unit to refer to the storage unit carrying out logical partition, for example, storage unit is
One piece of hard disk in server after the hard disk is carried out logical partition, can obtain the separated sub-disk of more than one logic.
In the present embodiment, the separated sub-disk of above-mentioned logic is divided into two classes, one kind is the first subelement, and another kind of is
Two word cells;Wherein, the first subelement is available storage region, can be with read/write data in the first subelement;Second son is single
Member is reserved storage region, when the first subelement breaks down, can store the first subelement by the second subelement
Copy data information.
Step 302:For first subelement setting first flag and it is that second subelement sets the second mark
Know.
Specifically, it is respectively that more than one first subelement sets first flag, for example, dividing the storage unit
Qu Hou obtains three the first subelements, then the first flag of these three the first subelements is respectively set to 1,2,3;Respectively one
A above second subelement sets second identifier, for example, after carrying out subregion to the storage unit, it is single to obtain two second sons
Member, then the second identifier of the two the second subelements be respectively set to A, B.
In the present embodiment, first flag and any combination that second identifier can be following character:Number, letter, symbol
Deng.
Step 303:When detecting that first subelement is in first state, according to the first of first subelement the mark
Know and searched and matched 3rd subelement of the first flag in the second electronic equipment.
Here, first state refers to that the first subelement is in unusable state, such as the first subelement is in damage shape
State or malfunction.
When the first subelement is in first state, the data in the first subelement are also at first state accordingly, such as
This from spare electronic equipment, it is necessary to obtain whole copy data information of the first subelement.
Second electronic equipment is spare electronic equipment, stores copy data information, it is preferable that the second electronic equipment also wraps
More than one storage unit is included, has also carried out subregion for each storage unit, it is necessary to illustrate, in the embodiment of the present invention
Electronic equipment is used based on electronic equipment, the second electronic equipment is spare electronic equipment, primary electronic equipment and spare electronic equipment
All there is identical data message, also, primary electronic equipment and spare electronic equipment are opposite, i.e., when primary electronic equipment
In storage unit when breaking down, can data recovery be carried out according to the data message in spare electronic equipment;Spare electronics
When storage unit in equipment breaks down, can also data recovery be carried out according to the data message in primary electronic equipment.
Second electronic equipment includes the 3rd subelement to match with the first subelement, and the 3rd subelement has the first son
The copy data information of unit.In this way, it can be searched according to the first flag of first subelement in the second electronic equipment
With matched 3rd subelement of the first flag.
Step 304:Order reads the total data information in the 3rd subelement, and as first subelement
Whole copy data information.
The data message of the 3rd subelement is read in a sequential manner, can improve the speed of digital independent.
Step 305:Whole copy data information of first subelement are stored to second subelement.
Step 306:By the second identifier of second subelement be arranged to first subelement first flag and
Second subelement is converted into first subelement.
Whole copy data information of first subelement are stored to second subelement, the second subelement
The function of being realized just is equivalent to the function that the first subelement is realized, for example, the first subelement stores A data, client is read
It takes during A data, it is necessary to the first subelement be accessed, when the first subelement is in first state, just by the whole of the first subelement
Copy data information is stored to the second subelement, in this way, the second subelement store A data, client read A data when, it is necessary to
Access the second subelement rather than the first subelement.
Preferably, when the number of second subelement is less than or equal to default threshold value, search in the second state
The first subelement;It is single that the first flag of the first subelement in the second state found is arranged to second son
The second identifier of member;The first subelement in the second state found is converted into the second subelement.
When the number of second subelement is less than certain amount, it can not just be stored when the first subelement is in first state
Whole copy data information of first subelement, for this reason, it may be necessary to search the first subelement being in idle condition, the present embodiment will
Idle state is known as the second state, then the first subelement being in idle condition is converted to the second subelement, meanwhile, it will convert
The second identifier of the second subelement is arranged to for the first flag of the first subelement of the second subelement.
In the present embodiment, when the first subelement is in first state, just by whole copy data information of the first subelement
It stores to the second subelement, the data message in fast quick-recovery electronic equipment, and makes full use of the transmission performance of I/O interfaces;
Also, the second subelement is converted into the first subelement and the second identifier of the second subelement is arranged to the first subelement
First flag, can realize client accurately access needed for data.
Fig. 4 is the flow diagram of the data processing method of the embodiment of the present invention, the data processing method in the present embodiment
Applied in electronic equipment, the electronic equipment includes more than one storage unit, in a preferred embodiment of the invention, number
Comprise the following steps according to processing method,
Step 401:Subregion is carried out to the storage unit, and obtain more than one first subelement and more than one the
Two subelements.
Here, the storage unit can be any form of storage medium such as disk.
It carries out subregion to residing storage unit to refer to the storage unit carrying out logical partition, for example, storage unit is
One piece of hard disk in server after the hard disk is carried out logical partition, can obtain the separated sub-disk of more than one logic.
In the present embodiment, the separated sub-disk of above-mentioned logic is divided into two classes, one kind is the first subelement, and another kind of is
Two word cells;Wherein, the first subelement is available storage region, can be with read/write data in the first subelement;Second son is single
Member is reserved storage region, when the first subelement breaks down, can store the first subelement by the second subelement
Copy data information.
Step 402:For first subelement setting first flag and it is that second subelement sets the second mark
Know.
Specifically, it is respectively that more than one first subelement sets first flag, for example, dividing the storage unit
Qu Hou obtains three the first subelements, then the first flag of these three the first subelements is respectively set to 1,2,3;Respectively one
A above second subelement sets second identifier, for example, after carrying out subregion to the storage unit, it is single to obtain two second sons
Member, then the second identifier of the two the second subelements be respectively set to A, B.
In the present embodiment, first flag and any combination that second identifier can be following character:Number, letter, symbol
Deng.
Step 403:When detecting that first subelement is in first state, according to the first of first subelement the mark
Know and searched and matched 3rd subelement of the first flag in the second electronic equipment.
Here, first state refers to that the first subelement is in unusable state, such as the first subelement is in damage shape
State or malfunction.
When the first subelement is in first state, the data in the first subelement are also at first state accordingly, such as
This from spare electronic equipment, it is necessary to obtain whole copy data information of the first subelement.
Second electronic equipment is spare electronic equipment, stores copy data information, it is preferable that the second electronic equipment also wraps
More than one storage unit is included, has also carried out subregion for each storage unit, it is necessary to illustrate, in the embodiment of the present invention
Electronic equipment is used based on electronic equipment, the second electronic equipment is spare electronic equipment, primary electronic equipment and spare electronic equipment
All there is identical data message, also, primary electronic equipment and spare electronic equipment are opposite, i.e., when primary electronic equipment
In storage unit when breaking down, can data recovery be carried out according to the data message in spare electronic equipment;Spare electronics
When storage unit in equipment breaks down, can also data recovery be carried out according to the data message in primary electronic equipment.
Second electronic equipment includes the 3rd subelement to match with the first subelement, and the 3rd subelement has the first son
The copy data information of unit.In this way, it can be searched according to the first flag of first subelement in the second electronic equipment
With matched 3rd subelement of the first flag.
Step 404:Order reads the total data information in the 3rd subelement, and as first subelement
Whole copy data information.
The data message of the 3rd subelement is read in a sequential manner, can improve the speed of digital independent.
Step 405:According to the second identifier of second subelement, searched in the electronic equipment and the described second mark
Know matched second subelement.
Step 406:Whole copy data information of first subelement are stored to the second subelement matched.
Step 407:By the second identifier of second subelement be arranged to first subelement first flag and
Second subelement is converted into first subelement.
Whole copy data information of first subelement are stored to second subelement, the second subelement
The function of being realized just is equivalent to the function that the first subelement is realized, for example, the first subelement stores A data, client is read
It takes during A data, it is necessary to the first subelement be accessed, when the first subelement is in first state, just by the whole of the first subelement
Copy data information is stored to the second subelement, in this way, the second subelement store A data, client read A data when, it is necessary to
Access the second subelement rather than the first subelement.
Preferably, when the number of second subelement is less than or equal to default threshold value, search in the second state
The first subelement;It is single that the first flag of the first subelement in the second state found is arranged to second son
The second identifier of member;The first subelement in the second state found is converted into the second subelement.
When the number of second subelement is less than certain amount, it can not just be stored when the first subelement is in first state
Whole copy data information of first subelement, for this reason, it may be necessary to search the first subelement being in idle condition, the present embodiment will
Idle state is known as the second state, then the first subelement being in idle condition is converted to the second subelement, meanwhile, it will convert
The second identifier of the second subelement is arranged to for the first flag of the first subelement of the second subelement.
In the present embodiment, when the first subelement is in first state, just by whole copy data information of the first subelement
It stores to the second subelement, the data message in fast quick-recovery electronic equipment, and makes full use of the transmission performance of I/O interfaces;
Also, the second subelement is converted into the first subelement and the second identifier of the second subelement is arranged to the first subelement
First flag, can realize client accurately access needed for data.
Fig. 5 is the flow diagram of the data processing method of the embodiment of the present invention, the data processing method in the present embodiment
Applied in electronic equipment, the electronic equipment includes more than one storage unit, in a preferred embodiment of the invention, number
Comprise the following steps according to processing method,
Step 501:Subregion is carried out to the storage unit, and obtain more than one first subelement and more than one the
Two subelements.
Here, the storage unit can be any form of storage medium such as disk.
It carries out subregion to residing storage unit to refer to the storage unit carrying out logical partition, for example, storage unit is
One piece of hard disk in server after the hard disk is carried out logical partition, can obtain the separated sub-disk of more than one logic.
In the present embodiment, the separated sub-disk of above-mentioned logic is divided into two classes, one kind is the first subelement, and another kind of is
Two word cells;Wherein, the first subelement is available storage region, can be with read/write data in the first subelement;Second son is single
Member is reserved storage region, when the first subelement breaks down, can store the first subelement by the second subelement
Copy data information.
Step 502:For first subelement setting first flag and it is that second subelement sets the second mark
Know.
Specifically, it is respectively that more than one first subelement sets first flag, for example, dividing the storage unit
Qu Hou obtains three the first subelements, then the first flag of these three the first subelements is respectively set to 1,2,3;Respectively one
A above second subelement sets second identifier, for example, after carrying out subregion to the storage unit, it is single to obtain two second sons
Member, then the second identifier of the two the second subelements be respectively set to A, B.
In the present embodiment, first flag and any combination that second identifier can be following character:Number, letter, symbol
Deng.
Step 503:When detecting that first subelement is in first state, count and institute is in first subelement
State the regional extent of first state.
For example, when detecting that first subelement is in damaged condition, count in first subelement in damage
The capacity of state.
Step 504:When the regional extent in the first state in first subelement is more than or equal to default
During scope, whole copy data information of first subelement are obtained, perform step 505;When in first subelement
When the regional extent of the first state is less than the default scope, obtain one by one in first subelement in described
The copy data information of the regional extent of first state performs step 506.
The present embodiment consider when in the first subelement be in first state regional extent it is smaller when, can be by one by one
Obtain in first state region copy data information carry out data recovery, when in the first subelement be in first state
Regional extent it is larger when, pass through the recovery that the whole whole copy data information for obtaining the first subelement carry out data.
It should be noted that described in either obtaining whole copy data information of first subelement, obtaining one by one
The copy data information of the regional extent in the first state, is all stored with copy data information in first subelement
It is got in stand-by equipment.
Step 505:Whole copy data information of first subelement are stored to second subelement.
Step 506:Will in first subelement in the first state regional extent copy data information by
Item is stored to second subelement.
In the present embodiment, the regional extent for being in first state to the first subelement first judges, when in first
When the regional extent of state is greater than or equal to default scope, just whole copy data information of the first subelement are stored to the
Two subelements, the data message in fast quick-recovery electronic equipment, and make full use of the transmission performance of I/O interfaces;When in
When the regional extent of one state is less than default scope, the copy data information of the first subelement is stored one by one single to the second son
Member saves Internet resources.
Fig. 6 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention, and the electronic equipment in the present embodiment includes
More than one storage unit, in a preferred embodiment of the invention, electronic equipment includes:Division module 61, acquisition module 62
And processing module 63;Wherein,
The division module 61, for the storage unit carry out subregion, and obtain more than one first subelement with
And more than one second subelement;
The acquisition module 62 during for detecting that first subelement is in first state, obtains first son
Whole copy data information of unit;
The processing module 63, for storing whole copy data information of first subelement to the described second son
Unit.
Fig. 7 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention, and the electronic equipment in the present embodiment includes
More than one storage unit, in a preferred embodiment of the invention, electronic equipment includes:Division module 61, mark module 64,
Acquisition module 62, processing module 63 and modular converter 65;Wherein,
The division module 61, for the storage unit carry out subregion, and obtain more than one first subelement with
And more than one second subelement;
The mark module 64, for setting first flag for first subelement and being second subelement
Second identifier is set;
The acquisition module 62 during for detecting that first subelement is in first state, obtains first son
Whole copy data information of unit;
The processing module 63, for storing whole copy data information of first subelement to the described second son
Unit;
The mark module 64 is additionally operable to work as the processing module by whole copy data information of first subelement
It stores to second subelement, the second identifier of second subelement is arranged to the first mark of first subelement
Know;
The modular converter 65, for second subelement to be converted to first subelement.
Preferably, the electronic equipment further includes:Searching module 66;
The searching module 66, for when the number of second subelement is less than or equal to default threshold value, searching
The first subelement in the second state;
The mark module 64, the first flag for being additionally operable to the first subelement in the second state that will be found are set
It is set to the second identifier of second subelement;
The modular converter 65, the first subelement in the second state for being additionally operable to be found are converted to the second son
Unit.
Fig. 8 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention, and the electronic equipment in the present embodiment includes
More than one storage unit, in a preferred embodiment of the invention, electronic equipment includes:Division module 61, mark module 64,
Acquisition module 62, processing module 63 and modular converter 65;Wherein,
The division module 61, for the storage unit carry out subregion, and obtain more than one first subelement with
And more than one second subelement;
The mark module 64, for setting first flag for first subelement and being second subelement
Second identifier is set;
The acquisition module 62 during for detecting that first subelement is in first state, obtains first son
Whole copy data information of unit;
The processing module 63, for storing whole copy data information of first subelement to the described second son
Unit;
The mark module 64 is additionally operable to work as the processing module by whole copy data information of first subelement
It stores to second subelement, the second identifier of second subelement is arranged to the first mark of first subelement
Know;
The modular converter 65, for second subelement to be converted to first subelement.
Preferably, the acquisition module 62 includes:Detection sub-module 621, first searches submodule 622 and reads submodule
Block 623;Wherein,
The detection sub-module 621 during for detecting that first subelement is in first state, notifies the lookup
Submodule;
Described first searches submodule 622, single according to the described first son after receiving the notice of the detection sub-module
The first flag of member is searched and matched 3rd subelement of the first flag in the second electronic equipment;
The reading submodule 623, for sequentially reading the total data information in the 3rd subelement, and as institute
State whole copy data information of the first subelement.
Preferably, the electronic equipment further includes:Searching module 66;
The searching module 66, for when the number of second subelement is less than or equal to default threshold value, searching
The first subelement in the second state;
The mark module 64, the first flag for being additionally operable to the first subelement in the second state that will be found are set
It is set to the second identifier of second subelement;
The modular converter 65, the first subelement in the second state for being additionally operable to be found are converted to the second son
Unit.
Fig. 9 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention, and the electronic equipment in the present embodiment includes
More than one storage unit, in a preferred embodiment of the invention, electronic equipment includes:Division module 61, mark module 64,
Acquisition module 62, processing module 63 and modular converter 65;Wherein,
The division module 61, for the storage unit carry out subregion, and obtain more than one first subelement with
And more than one second subelement;
The mark module 64, for setting first flag for first subelement and being second subelement
Second identifier is set;
The acquisition module 62 during for detecting that first subelement is in first state, obtains first son
Whole copy data information of unit;
The processing module 63, for storing whole copy data information of first subelement to the described second son
Unit;
The mark module 64 is additionally operable to work as the processing module by whole copy data information of first subelement
It stores to second subelement, the second identifier of second subelement is arranged to the first mark of first subelement
Know;
The modular converter 65, for second subelement to be converted to first subelement.
Preferably, the acquisition module 62 includes:Detection sub-module 621, first searches submodule 622 and reads submodule
Block 623;Wherein,
The detection sub-module 621 during for detecting that first subelement is in first state, notifies the lookup
Submodule;
Described first searches submodule 622, single according to the described first son after receiving the notice of the detection sub-module
The first flag of member is searched and matched 3rd subelement of the first flag in the second electronic equipment;
The reading submodule 623, for sequentially reading the total data information in the 3rd subelement, and as institute
State whole copy data information of the first subelement.
Preferably, the processing module 63 includes:Second searches submodule 631, sub-module stored 632;Wherein,
Described second searches submodule 631, for the second identifier according to second subelement, in the electronic equipment
Middle lookup and matched second subelement of the second identifier;
The sub-module stored 632, for storing whole copy data information of first subelement to matching
The second subelement.
Preferably, the electronic equipment further includes:Searching module 66;
The searching module 66, for when the number of second subelement is less than or equal to default threshold value, searching
The first subelement in the second state;
The mark module 64, the first flag for being additionally operable to the first subelement in the second state that will be found are set
It is set to the second identifier of second subelement;
The modular converter 65, the first subelement in the second state for being additionally operable to be found are converted to the second son
Unit.
Figure 10 is the structure composition schematic diagram of the electronic equipment of the embodiment of the present invention, and the electronic equipment in the present embodiment includes
More than one storage unit, in a preferred embodiment of the invention, electronic equipment includes:Division module 61, statistical module 67,
Acquisition module 62 and processing module 63;Wherein,
The division module 61, for the storage unit carry out subregion, and obtain more than one first subelement with
And more than one second subelement;
The statistical module 67, for counting the regional extent that the first state is in first subelement, when
When the regional extent in the first state is greater than or equal to default scope in first subelement, the first notice is sent
Message is to the acquisition module 62;When the regional extent that the first state is in first subelement is less than described preset
Scope when, send second notification message to the acquisition module 62;
The acquisition module 62 after receiving the first notification message that the statistical module 67 is sent, obtains described the
Whole copy data information of one subelement;
Correspondingly, the processing module 63, for storing whole copy data information of first subelement to institute
State the second subelement;
The acquisition module 62 is additionally operable to after receiving the second notification message that the statistical module 67 is sent, obtains one by one
The copy data information of regional extent in the first state in first subelement;
Correspondingly, the processing module 63 is additionally operable to that the region of the first state will be in first subelement
The copy data information of scope is stored one by one to second subelement.
Obviously, those skilled in the art should be understood that each processing module of the above-mentioned present invention or each step can be used
General computing device is realized, can concentrate on single computing device or be distributed in multiple computing device institutes group
Into network on, optionally, can be realized with the program code that computing device can perform, it is thus possible to which they are stored
In the storage device by computing device come perform either they are fabricated to respectively each integrated circuit modules or by they
In multiple modules or step be fabricated to single integrated circuit module to realize.In this way, the present invention is not limited to any specific
Hardware and software combines.
Figure 11 is the schematic diagram of storage unit in electronic equipment in the embodiment of the present invention, and as shown in figure 11, left figure part is
Primary electronic equipment, right figure part are spare electronic equipment;Wherein, it is respectively there are three storage unit in primary electronic equipment
First storage unit, the second storage unit and the 3rd storage unit;Correspondingly, it is also single there are three storage in spare electronic equipment
Member is respectively the 4th storage unit, the 5th storage unit and the 6th storage unit.
It is 9 regions by the first storage unit subregion, as shown in figure 11, to each region by taking the first storage unit as an example
After being identified, 9 regions of the first storage unit are respectively:1、2、3、4、5、6、7、8、A;Wherein, 1 to 8 region is first
Subelement, A are the second subelement.
Similarly, the first subelement of the second storage unit is:9、10、11、12、13、14、15、16;Second subelement is B.
First subelement of the 3rd storage unit is:17、18、19、20、21、22、23、24;Second subelement is C.
The 4th storage unit, the 5th storage unit and the 6th storage unit in spare electronic equipment store primary electricity
The copy data of sub- equipment as shown in figure 11, loses whole data, the 4th storage unit when being damaged in order to avoid storage unit
The 3rd subelement be:1、2、3、15、16、20、21、22;4th subelement is D.
Similarly, the 3rd subelement of the 5th storage unit is:12、13、14、4、5、6、23、24;4th subelement is E.
3rd subelement of the 6th storage unit is:17、18、19、9、10、11、7、8;4th subelement is F.
In the present embodiment, the first subelement in the data message and host apparatus of the 3rd subelement in stand-by equipment
Data message correspond, as shown in figure 11, when in host apparatus the first storage unit the first subelement 7 damage when, it is necessary to
It is searched in stand-by equipment and 7 matched 3rd subelements, the then data in the 3rd subelement 7 of acquisition, and copying to primary
In second subelement B of the first storage unit of equipment.
Then, the second subelement is converted into the first subelement, and the mark B of the second subelement is arranged to the first son list
The mark 7 of member, in this way, the first storage unit in host apparatus is recovered.
The foregoing is only a preferred embodiment of the present invention, is not intended to limit the scope of the present invention.
Claims (12)
1. a kind of data processing method, applied in electronic equipment, the electronic equipment includes more than one storage unit, special
Sign is, the described method includes:
Subregion is carried out to the storage unit, and obtains more than one first subelement and more than one second subelement;
When detecting that first subelement is in first state, count and the first state is in first subelement
Regional extent, wherein, the first state refers to that first subelement is in unusable state;
When the regional extent that the first state is in first subelement is greater than or equal to default scope, institute is obtained
State whole copy data information of the first subelement;
Whole copy data information of first subelement are stored to second subelement.
2. data processing method according to claim 1, which is characterized in that the method further includes:
For first subelement setting first flag and it is that second subelement sets second identifier;
Whole copy data information of first subelement are stored to second subelement, the described second son is single
The second identifier of member is arranged to the first flag of first subelement and second subelement is converted to described first
Subelement.
3. data processing method according to claim 2, which is characterized in that described to detect that first subelement is in
During first state, whole copy data information of first subelement are obtained, including:
When detecting that first subelement is in first state, according to the first flag of first subelement in the second electronics
It is searched and matched 3rd subelement of the first flag in equipment;
Order reads the total data information in the 3rd subelement, and as whole copy datas of first subelement
Information.
4. data processing method according to claim 3, which is characterized in that described by all secondary of first subelement
Notebook data information is stored to second subelement, including:
According to the second identifier of second subelement, searched and the second identifier matched second in the electronic equipment
Subelement;
Whole copy data information of first subelement are stored to the second subelement matched.
5. according to claim 2 to 4 any one of them data processing method, which is characterized in that the method further includes:
When the number of second subelement is less than or equal to default threshold value, it is single to search the first son in the second state
Member, wherein, second state refers to idle state;
The first flag of the first subelement in the second state found is arranged to the second of second subelement
Mark;
The first subelement in the second state found is converted into the second subelement.
6. data processing method according to any one of claims 1 to 4, which is characterized in that the method further includes:
When the regional extent that the first state is in first subelement is less than the default scope, obtain one by one
The copy data information of regional extent in the first state in first subelement;It will be in first subelement
It is stored one by one to second subelement in the copy data information of the regional extent of the first state.
7. a kind of electronic equipment, the electronic equipment includes more than one storage unit, which is characterized in that the electronic equipment bag
It includes:Division module, statistical module, acquisition module and processing module;Wherein,
The division module for carrying out subregion to the storage unit, and obtains more than one first subelement and one
More than the second subelement;
The statistical module, for counting the regional extent that first state is in first subelement, when the described first son
When the regional extent in the first state is greater than or equal to default scope in unit, the first notification message is sent to described
Acquisition module, wherein, the first state refers to that first subelement is in unusable state;
The acquisition module is additionally operable to after receiving the first notification message that the statistical module is sent, and it is single to obtain first son
Whole copy data information of member;
The processing module, for storing whole copy data information of first subelement to second subelement.
8. electronic equipment according to claim 7, which is characterized in that the electronic equipment further includes:Mark module and
Modular converter;Wherein,
The mark module, for setting first flag for first subelement and be second subelement setting the
Two marks;When the processing module stores whole copy data information of first subelement to second subelement
Afterwards, the second identifier of second subelement is arranged to the first flag of first subelement;
The modular converter, for second subelement to be converted to first subelement.
9. electronic equipment according to claim 8, which is characterized in that the acquisition module includes:Detection sub-module, first
Search submodule and reading submodule;Wherein,
The detection sub-module during for detecting that first subelement is in first state, notifies described first to search son
Module;
Described first searches submodule, after receiving the notice of the detection sub-module, according to the of first subelement
One mark is searched and matched 3rd subelement of the first flag in the second electronic equipment;
The reading submodule for sequentially reading the total data information in the 3rd subelement, and is used as described first
Whole copy data information of subelement.
10. electronic equipment according to claim 9, which is characterized in that the processing module includes:Second searches submodule
Block, sub-module stored;Wherein,
Described second searches submodule, for the second identifier according to second subelement, is searched in the electronic equipment
With matched second subelement of the second identifier;
The sub-module stored, for storing whole copy data information of first subelement to the second son matched
Unit.
11. according to claim 8 to 10 any one of them electronic equipment, which is characterized in that the electronic equipment further includes:It looks into
Look for module;
The searching module, for when the number of second subelement is less than or equal to default threshold value, searching in the
First subelement of two-state, wherein, second state refers to idle state;
The mark module, the first flag for being additionally operable to the first subelement in the second state that will be found are arranged to institute
State the second identifier of the second subelement;
The modular converter, the first subelement in the second state for being additionally operable to be found are converted to the second subelement.
12. according to claim 7 to 10 any one of them electronic equipment, which is characterized in that the statistical module, for working as
When stating the regional extent that the first state is in the first subelement less than the default scope, second notification message is sent
To the acquisition module;
The acquisition module is additionally operable to after receiving the second notification message that the statistical module is sent, obtains described first one by one
The copy data information of regional extent in the first state in subelement;
Correspondingly, the processing module is additionally operable to that the regional extent of the first state will be in first subelement
Copy data information is stored one by one to second subelement.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310392475.5A CN104424049B (en) | 2013-09-02 | 2013-09-02 | A kind of data processing method and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310392475.5A CN104424049B (en) | 2013-09-02 | 2013-09-02 | A kind of data processing method and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104424049A CN104424049A (en) | 2015-03-18 |
CN104424049B true CN104424049B (en) | 2018-06-01 |
Family
ID=52973102
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310392475.5A Active CN104424049B (en) | 2013-09-02 | 2013-09-02 | A kind of data processing method and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104424049B (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1550990A (en) * | 2003-05-19 | 2004-12-01 | 日立环球储存科技荷兰有限公司 | System and method for sparing in raid-1 system |
CN101452465A (en) * | 2007-12-05 | 2009-06-10 | 高德软件有限公司 | Mass file data storing and reading method |
CN101923501A (en) * | 2010-07-30 | 2010-12-22 | 华中科技大学 | Disk array multi-level fault tolerance method |
CN102131002A (en) * | 2011-03-29 | 2011-07-20 | 华为终端有限公司 | Method and device for processing mobile phone data |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5169993B2 (en) * | 2009-05-27 | 2013-03-27 | 日本電気株式会社 | Data storage system and data area management method |
-
2013
- 2013-09-02 CN CN201310392475.5A patent/CN104424049B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1550990A (en) * | 2003-05-19 | 2004-12-01 | 日立环球储存科技荷兰有限公司 | System and method for sparing in raid-1 system |
CN101452465A (en) * | 2007-12-05 | 2009-06-10 | 高德软件有限公司 | Mass file data storing and reading method |
CN101923501A (en) * | 2010-07-30 | 2010-12-22 | 华中科技大学 | Disk array multi-level fault tolerance method |
CN102131002A (en) * | 2011-03-29 | 2011-07-20 | 华为终端有限公司 | Method and device for processing mobile phone data |
Also Published As
Publication number | Publication date |
---|---|
CN104424049A (en) | 2015-03-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN102866954B (en) | The method of Memory Allocation and device | |
CN109656896B (en) | Fault repairing method and device, distributed storage system and storage medium | |
CN104461390A (en) | Method and device for writing data into imbricate magnetic recording SMR hard disk | |
CN103034567B (en) | Find and repair the apparatus and method of corrupt data | |
CN102594596B (en) | Method and device for recognizing available partitions, and clustering network system | |
CN105830041A (en) | Metadata recovery method and apparatus | |
CN103455379A (en) | Resource allocation method and system | |
US20170083406A1 (en) | Method and apparatus for incremental backup | |
CN105808407A (en) | Equipment management method, equipment and equipment management controller | |
CN105159800A (en) | Data recovery method, data backup method, data recovery equipment, data backup equipment, data recovery system and data backup system | |
US10346073B2 (en) | Storage control apparatus for selecting member disks to construct new raid group | |
CN101833513B (en) | Device and reading method for data frame | |
CN105183399A (en) | Data writing and reading method and device based on elastic block storage | |
CN102959548A (en) | Data storage method, search method and device | |
CN111478856A (en) | Master-slave mode-based addressing method and system for communication route between dual redundant devices | |
CN102624537B (en) | Data recovery system and method thereof | |
CN103905310A (en) | Message processing method and forwarding device | |
CN104424049B (en) | A kind of data processing method and electronic equipment | |
CN108345519A (en) | The processing method and processing device of hard disc of computer failure | |
CN103064766B (en) | Fast data synchronization method in continuous data protection technology | |
CN104376093A (en) | Searching method and device for video files | |
CN103761202A (en) | Data storage node hard disk position identification method and system | |
CN101419563A (en) | Single board and method for enhancing reliability of the single board | |
CN105159790A (en) | Data rescue method and file server | |
CN114564458B (en) | Method, device, equipment and storage medium for synchronizing data among clusters |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |